I am unable to find the documentation on how to set it up with SVN. Am I missing something? I have tried in my deploy.php file:
require 'recipe/common.php';
server('ec2', 'server')
->user('user')
->pemFile('key.pem')
->env('deploy_path', '/var/www/website');
set('repository', 'http://user:[email protected]/repos/branches/development/');
I think that that is looking for a git file though. Can you help please?
Many thanks!
Overriding tasks is quite easy. Here, is a sample of deploy.php to use svn export functionality to achieve deployment from svn repository:
//Set svn specific variables
set('svnrepo', 'http://x.x.x.x/repos/branches/development/');
set('svnuser', 'user');
set('svnpass', 'password');
/**
* Update project code, override git, use svn instead.
*/
task('deploy:update_code', function () {
$svn = '/usr/bin/svn';
$repository = trim(get('svnrepo'));
$user = trim(get('svnuser'));
$pass = trim(get('svnpass'));
run("$svn export --force --username $user --password $pass $repository {{release_path}} 2>&1");
})->desc('Updating code');
Also it could be written as svn up command, but in my personal opinion, who needs .svn files in prod environments?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With