Jeremy Olliver edited this page Sep 4, 2013 · 6 revisions

Further details and examples on using easy-deployment features

Apache (passenger)

Seamlessly configure your VirtualHost in sites-available from your application source code.


Integrated backup to Amazon S3 via the backup gem.


Don't run out of disk space. Ensure your rails logs are rotated frequently.


Deployments running slow? See which steps are taking the longest.

Other common deployment patterns

Deploying with rvm

If deploying with RVM, Add gem 'rvm-capistrano' to the development group in Gemfile, and use the following in your deploy.rb or staging.rb etc:

require "rvm/capistrano"
set :rvm_type, :system
set :rvm_ruby_string, '1.9.2-p290'

Using gem groups to limit installation of a gem in certain environments

# Gemfile
group :staging
  gem 'mailcatcher'
# deploy.rb
set :bundle_without, defer { ["development", "test"] + fetch(:stages) - [fetch(:stage)] } # Bundle without other stage environments

This sets the bundle_without variable to ["development", "test", "staging"] for a production deploy for example.