require "bundler/capistrano"
bundle exec rake RAILS_ENV=production RAILS_GROUPS=assets assets:precompile
在执行 bundel exec cap deploy 这个任务的时候想加入 rake 的 trace 参数....
set :application, "dom1"
set :user,"root"
set :password,"321654"
set :repository, "[email protected]:huxinghai1988/capistrano_dom"
set :domain,"192.168.2.27"
default_run_options[:pty] = true
set :use_sudo,false
set :scm, "git"
set :scm_user,"root"
set :scm_passphrase,"huxinghai"
set :deploy_to,"/var/www/#{application}"
set :branch, "master"
set :rails_env, 'production'
role :web, domain
role :app, domain
role :db, domain, :primary => true
set :rvm_path,"/usr/local/rvm"
set :rvm_bin_path,"/usr/local/rvm/bin"
set :rvm_ruby_string,'ruby-1.9.2'
require 'rvm/capistrano'
require 'bundler/capistrano'
before 'deploy:setup' do
run 'echo insecure > ~/.curlrc', :shell => 'bash -c'
find_and_execute_task "rvm:install_rvm"
find_and_execute_task 'rvm:install_ruby'
end
load 'deploy/assets'