欢迎访问 生活随笔!

ag凯发k8国际

当前位置: ag凯发k8国际 > 编程语言 > php >内容正文

php

deploy.php -ag凯发k8国际

发布时间:2023/12/10 php 166 豆豆
ag凯发k8国际 收集整理的这篇文章主要介绍了 deploy.php 小编觉得挺不错的,现在分享给大家,帮大家做个参考.
php namespace deployer;require 'recipe/common.php';// project name set('application', 'tp_web');// project repository set('repository', 'git地址');// [optional] allocate tty for git clone. default value is false. set('git_tty', true); // shared files/dirs between deploys set('shared_files', []); set('shared_dirs', []);// writable dirs by web server set('writable_dirs', []);set('keep_releases', 15);// hosts host('localhost')->user('www-data')->set('branch', 'master')->set('deploy_path', '部署地址'); // tasks desc('deploy your project'); task('deploy', ['deploy:info','deploy:prepare','deploy:lock','deploy:release','deploy:update_code','deploy:shared','deploy:writable',//'deploy:vendors','deploy:clear_paths','deploy:symlink','deploy:unlock','cleanup','success' ]);task('moveconfig', function(){run('cp /home/workspace/files/config_master.php /www/current/application/config.php'); });task('movedatabase', function(){run('cp /home/workspace/files/database_master.php /www/current/application/database.php'); });task('createruntime', function(){run('mkdir /www/current/runtime');run('mkdir /www/current/runtime/cache');run('mkdir /www/current/runtime/log');run('mkdir /www/current/runtime/temp');run('mkdir /www/current/runtime/tlogs'); });task('curl', function(){run('curl http://url/reset.php');run('curl http://url/reset.php'); });// [optional] if deploy fails automatically unlock. after('deploy:failed', 'deploy:unlock'); after('deploy:unlock', 'moveconfig'); after('moveconfig', 'movedatabase'); after('movedatabase', 'curl'); after('curl', 'createruntime');

 

转载于:https://www.cnblogs.com/dongbo/p/11237299.html

总结

以上是ag凯发k8国际为你收集整理的deploy.php的全部内容,希望文章能够帮你解决所遇到的问题。

如果觉得ag凯发k8国际网站内容还不错,欢迎将ag凯发k8国际推荐给好友。

  • 上一篇:
  • 下一篇:
网站地图