Druploy is an agile deployment tool based on Fabric and Drush that makes deploying instances of Drupal projects fast and easy. It depends on the Chef Drupal Cookbook.
There are some other Drupal deployment tools available (e.g Aegir is an amazing tool) but they are quite heavy and don't work as I would like with a number of commun scenarios.
Druploy intends to ease some very standard, day to day problems in the workflow of a Drupal agency.
- Enable the quick onboarding of a new developer into an existing project (by being able to type a single command to have a working copy of a project set up on his machine).
- Make it easy to show a customer a development/developer branch on a publicly accessable new staging vhost.
- Make it easy for developers to move code/files/databases between development and staging machines.
- Be able to deploy a new site based on a branch and database/file snapshots in a single command.
- Make feature branching a single command (druploy branch command will create a new local git branch, database, files and update settings files).
Fabric>=1.8. Druploy wont work for versions less then 1.8 and will mostly cause cryptic errors.
Openssh-client and Openssh-server. Druploy uses ssh connections to make changes even in the local machine. The user will be prompted for password input every time a local change is to be made. To avoid this the recommanded setup is to create a passphraseless set of ssh keys and map them in the ssh config file:
Host localhost IdentityFile <path/to/private/key>
- A remote server configured with Git, Drush, PHP, Apache, Apache_mod rewrite, MySQl. The best shortcut to configure the remote server is to use the chef Drupal recipe Drupal Cookbook
- Add drupal to your PATH, if you are using bash:
$ echo 'export PATH="/path/to/druploy/bin/:$PATH' >> ~/.bashrc $ source ~/.bashrc
- Create a new servers config file from the example.
$ cd /path/to/druploy/folder/ $ cp examples/servers.yaml servers.yaml
Note: All .yaml files are .gitignored.
- Configure the correct usernames and passwords in servers.yaml
The following example will collect:
- Code managed by git in a branch called "test".
from a project not managed by Druploy, and deploy them to the domain www.mydrupalsite.com on the server named "live" in your servers.yaml
$ druploy server:local \ source:/path/to/drupal/sites/default \ code:firstname.lastname@example.org:repo.git,branch=test database:updating=True files:updating=True \ server:live project:new deploy:live domain:www.mydrupalsite.com