开发者

Capistrano php/apache rollback

开发者 https://www.devze.com 2022-12-20 04:36 出处:网络
Let\'s say you have a project running on apache. I use capistrano开发者_StackOverflow to deploy new code and update a httpd.conf/other configuration files, I then reload all of my services (reloading

Let's say you have a project running on apache. I use capistrano开发者_StackOverflow to deploy new code and update a httpd.conf/other configuration files, I then reload all of my services (reloading the configs).

How is rollback managed? I wouldn't assume cap rollback would put the old configs in place and reload. Is this possible? Can you show me an example?

Is there a better way of managing configuration?


Capistrano comes with built-in recipes to manage Rails application rollbacks. They may work for your PHP/Apache deployment...but if they don't you can easily write your own Cap recipies in Ruby. You'll have to try it out on a test server to see how it works.


I ended up making my own hooks into deploy_code and on_rollback that copied the apache conf from the repository and reloaded apache.

0

精彩评论

暂无评论...
验证码 换一张
取 消