测试环境发布脚本
parent
b0e7957550
commit
365919306b
|
|
@ -0,0 +1,45 @@
|
|||
<?php
|
||||
|
||||
namespace Deployer;
|
||||
|
||||
require 'recipe/laravel.php';
|
||||
|
||||
// Project name
|
||||
set('application', 'my_project');
|
||||
|
||||
// Project repository
|
||||
set('repository', 'git@gitee.com:zi-chunsheng-e-commerce/mall-server.git');
|
||||
|
||||
// [Optional] Allocate tty for git clone. Default value is false.
|
||||
set('git_tty', true);
|
||||
|
||||
// Shared files/dirs between deploys
|
||||
add('shared_files', []);
|
||||
add('shared_dirs', []);
|
||||
|
||||
// Writable dirs by web server
|
||||
add('writable_dirs', []);
|
||||
|
||||
|
||||
// Hosts
|
||||
|
||||
host('test.zichunsheng.cn')
|
||||
->user('deployer')
|
||||
->port(22)
|
||||
->identityFile('~/.ssh/deployer_rsa')
|
||||
->forwardAgent(true)
|
||||
->multiplexing(true)
|
||||
->addSshOption('UserKnownHostsFile', '/dev/null')
|
||||
->addSshOption('StrictHostKeyChecking', 'no')
|
||||
->stage('test')
|
||||
->set('branch', 'develop')
|
||||
->set('deploy_path', '/www/wwwroot/test.zichunsheng.cn');
|
||||
|
||||
// Tasks
|
||||
|
||||
// [Optional] if deploy fails automatically unlock.
|
||||
after('deploy:failed', 'deploy:unlock');
|
||||
|
||||
// Migrate database before symlink new release.
|
||||
|
||||
before('deploy:symlink', 'artisan:migrate');
|
||||
Loading…
Reference in New Issue