Last active
August 29, 2015 14:04
-
-
Save theSociableme/6ff35eb7f3f8bc8c4db4 to your computer and use it in GitHub Desktop.
Capistrano
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add to Gemfile | |
gem 'capistrano' | |
gem 'capistrano-ext' | |
gem 'capistrano-rvm' | |
gem 'capistrano-rails' | |
gem 'capistrano-bundler' | |
Install Capistrano | |
cap install | |
Add the following to the middle of the Capfile | |
require 'capistrano/rvm' | |
require 'capistrano/bundler' | |
require 'capistrano/rails/assets' | |
require 'capistrano/rails/migrations' | |
Add the following to the end of the Capfile | |
Dir.glob('lib/capistrano/**/*.rb').each { |r| import r } | |
Update ~/.rvmrc file to fix RVM is not a function | |
export rvm_path="/home/app_user/.rvm" | |
export rvm_project_rvmrc=1 | |
export rvm_gemset_create_on_use_flag=1 | |
export rvm_trust_rvmrcs_flag=1 | |
# get rvm for non-interactive shells (eg capistrano) too | |
export BASH_ENV=$HOME/.bashrc | |
export rvm_is_not_a_shell_function=0 | |
# If not running interactively, don't do anything | |
[ -z "$PS1" ] && return |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment