Created
March 3, 2011 03:28
-
-
Save benoror/852286 to your computer and use it in GitHub Desktop.
File: benoror@macmini:~/simpleapp/config/deploy.rb
This file contains hidden or 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
default_run_options[:pty] = true | |
set :user, 'benoror' | |
set :domain, 'simpleapp.com' | |
set :application, 'simpleapp' | |
# the rest should be good | |
set :repository, "#{user}@#{domain}:#{application}.git" | |
set :deploy_to, "/home/#{user}/#{domain}" | |
set :deploy_via, :remote_cache | |
set :scm, 'git' | |
set :branch, 'master' | |
#set :git_shallow_clone, 1 | |
set :scm_verbose, true | |
set :use_sudo, false | |
server domain, :app, :web, :db, :primary => true | |
after "deploy:restart", "deploy:search_index" | |
namespace :deploy do | |
desc "Restart Passenger" | |
task :restart do | |
run "touch #{current_path}/tmp/restart.txt" | |
end | |
desc "Index Search" | |
task :search_index, :roles => :app do | |
run "cd #{current_path} && rake ts:index RAILS_ENV=production" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment