A toolkit for professional deployment using Capistrano v3.
Parts of the documentation and some of the tasks are geared towards WordPress plugin or theme deployments, but the toolkit can be used for almost all sort of deployments.
This toolkit is based on the WP Stack deployment tool created by Mark Jaquith. His toolkit is for Capistrano v2 and is not compatible with the new Capistrano v3.
You should have a professional deployment for your software. You should be using:
- Version control (like Git). It's actually mandatory for AVH Deploy.
- A code deployment system (like Capistrano)
- A staging environment to test changes before they go live
Additionally, you should be able to easily scale out to multiple web servers, if needed.
AVH Deploy is a toolkit that helps you do all that.
Capistrano is a code deployment tool. When you have code that is ready to go "live", this is what does it.
- Ruby >= 1.9 (JRuby and C-Ruby/YARV are supported)
I could not write it better myself, so just follow the Authentication & Authorisation instructions of Capistrano itself
- Install Ruby. I personally recommend using rbenv, but choose the installation method you are comfortable with.
- Checkout AVH Deploy
git clone firstname.lastname@example.org:petervanderdoes/AVH-Deploy.git /opt/avh-deploy
- Go to the directory you checked out AVH Deploy and run
- Customize the above renamed files.
- Create the directory you defined at
cdto the AVH Deploy directory.
cap production deploy(to deploy to staging, use
cap staging deploy)
cdto the AVH Deploy directory.
cap production deploy:rollback
There are two "stages": production and staging. These can be completely different servers, or different paths on the same set of servers.
lib/capistrano/tasks there are several tasks defined you can use for the deployment process. The tasks have "documentation" in the files themselves.
- This repository will be a rolling release, meaning we only use a master branch and we don't use tags.
- Even though the documentation and certain tasks are geared towards WordPress you can use AVH Deploy for more than WordPress
The MIT License (MIT)
Copyright (c) 2012-2013 Peter van der Does
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.