Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Ruby
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib
.gitignore
Gemfile
LICENSE.txt
README.md
Rakefile
capistrano-tools.gemspec

README.md

Capistrano::Tools

It is a collection of scripts for capistrano

  • unicorn deploy script
  • script to manage config yml fails (prompt paswords on deploy:setup)

Installation

Add this line to your application's Gemfile:

gem 'capistrano-tools'

And then execute:

$ bundle

Usage

Unicorn

Require the gem in your deploy script

require 'capistrano-tools'

add deploy restart after callback for unicorn

after 'deploy:restart', 'unicorn:reload'

You can set following variables for unicorn:

  • unicorn_env : unicron environment, defaults to rails_env or env.
  • unicorn_pid : location of unicron pid file, defaults to shared/pids folder
  • unicorn_bundle : path to bundle library, defaults to bundle_cmd or "bundle"
  • unicorn_bin : path to unicron library, defaults to 'unicron'

** If your are using unicron with unix socket file, do not locate it in to current directory. **

Templater

Require the gem in your deploy script

require 'capistrano-tools'

Create template and set templater variable:

set :templater, :template_dir => "lib/capistrano/templates", :templates => ['database']

TODO

  • create generator to create default files (config/unicorn/production.rb, config/deploy.rb, config/deploy/production.rb, Capfile)

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request
Something went wrong with that request. Please try again.