:bin_cmd
- Command used to execute binaries within the context of the app.
For instance, caplets/bundle
sets this to gem exec
. (default: nil
)
:environment
- The environment for this deployment, used as RAILS_ENV among
other things. (default: production
)
:required_children
- Directories that need to exist in the project root.
These will be created during deploy:setup
. This is the caplets replacement
of :shared_children
. (default: %w[config log public tmp/pids]
)
:server_processes
- Number of backend processes (ie, mongrels or unicorn
workers) to run. (default: 2
)
:server_port
- Port number on which to bind backend processes.
(default: 8000
)
:user
- UNIX user as which to login and run deploys. (default: deploy
)
Bundler 0.9+ support. By default, run after every code update, this bundle install
s gems into the project (not into system gems to avoid using sudo
).
:bundle_exclude
- Bundler groups to exclude from installation. Passed to
bundler's --without
switch. (default: %w[development test]
)
:bundle_roles
- The server roles on which to bundle. (default: [:app]
)
:bundle_to
- Subdirectory of the application in which to put installed gems.
Passed as an argument to bundle install
. (default: vendor/bundled_gems
)
deploy:bundle:install
- Runs a bundle install
to install needed gems from
the application's Gemfile.
deploy:bundle:install
after deploy:update_code
Tasks to support using ActiveRecord within your applications. This module
adds functionality to write out your database.yml
file and provides a
deploy:migrations
task.
Differently from capistrano defaults, caplets does not expect your code to be
deployed to your DB server. This means you don't even have to list it in your
deploy file. Instead, it expects to run your migrations from your :primary :app
server.
:db_host
- default: localhost
:db_adapter
- default: mysql
:db_database
- default: <application>_<environment>
:db_username
- default: <user>
:db_password
- default: <prompt for value>
:db_encoding
- default: `utf8'
These variables are used to set the corresponding values in your
database.yml
file. These values will be scoped appropriately under a key
for your current :environment
. If you'd rather, you can specify the entire
database.yml
yourself using :db_confg
:db_extra
- A hash of values merged into your :db_config, outside of any
environment key. Useful for adding access to slaves or other DBs.
(default: {})
deploy:db:config
- Write a generated database.yml
to your project's config
directory.
deploy:migrate
- Run rake db:migrate
on your primary app server.
deploy:migrations
- Do a deploy with migrations, including doing a
web:disable
first and restarting (not reloading) the backends
deploy:db:config
after deploy:setup
Automatically tag a revision on deploy.
git:tag_current_release
- Tag the :current_revision
with a tag like
deploy-<environment>-<timestamp>
and push it to the origin.
git:tag_current_release
after deploy:migrations
git:tag_current_release
after deploy:quick
git:tag_current_release
after deploy:rebuild
Support for keeping track of memcached nodes and writing a memcached.yml
config file based on the :memcached
role.
:memcached_servers
- An array of 'host:port' strings of memcached servers.
If any of your servers have the :memcached
role, this is constructed
dynamically based on those servers' :private_ip
s. Otherwise:
(default: %w[localhost:11211]
)
deploy:memcached:config
- Write a generated memcached.yml
to your
project's config directory.
deploy:memcached:config
after deploy:setup
Tasks that present a list of your configured servers, and provide quick SSH access to any of them. The server list can optionally be narrowed down by role.
ssh
- Connects to any configured server. (Usage: cap <environment> ssh
)
ssh:app
- Connects to any configured app server.
ssh:web
- Connects to any configured web server.