Reputation: 12019
I have 40 servers spread world-wide. All running centos lamp.
I'm using git and I want every change to production
branch to be deployed to each of those machines. Each machine has it's own config.php
and few other machine specific files.
Currently commits to production
branch trigger hudson build task with phing running phpunit tests, php-md, cpd and etc. The question is, how to deploy it to each of my machines,
preferably with running selenium tests on/for each of the updated servers, prior to making it live.
I've looked into capistrano, but I totally don't want to mix ruby and add this dependencies in my team.
Your suggestions for php multi server CI deployment ?
As an option, run a web-hook on commit, launching phing
build on each of the machines,
where in the build configuration I'll specify which repo to clone, which files to leave at place and which to replace.
Although this would fail if I suddenly push a bugged build.xml
file which will prevent me from rebuilding / reverting without 40 manual interruptions. + no reverting option.
Upvotes: 0
Views: 434
Reputation: 1803
Well, If you want to deploy to servers you can use a service like deployhq.com, or if you prefer to do it yourself take look at deployogi. Its based on bash and deployogi-hooks, and these hooks can be phpscripts (or whatever has mode 755).
Upvotes: 0
Reputation: 12019
Ended up with a bit customized git flow, where a post-receive
hook triggered build scripts via and CI server. The build result was placed in a folder that was lately synched with rsync
to all those 40 servers.
The config.php for each server had been left in the git repo itself
and php's auto_perpend_file
directive was set in the vhost
config to load the correct
config.php
file for the current server.
Upvotes: 1