Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

52 lines (37 sloc) 1.182 kb
load 'deploy' if respond_to?(:namespace) # cap2 differentiator
Dir['vendor/gems/*/recipes/*.rb','vendor/plugins/*/recipes/*.rb'].each { |plugin| load(plugin) }
require 'bundler/capistrano'
set :application, "telepaper"
set :deploy_to, "/srv/rails/#{application}"
set :scm, :git
set :repository, "git@github.com:newspaperclub/telepaper.git"
set :branch, "master"
set :deploy_via, :remote_cache
set :user, "rails"
set :group, "rails"
set :use_sudo, false
set :rails_env, "production"
set :location, "glu"
# set :location, "kusanagi.tomtaylor.co.uk"
set :port, "2222"
set :ssh_options, { :forward_agent => true }
role :app, location
role :web, location, :primary => true
role :db, location, :primary => true
after "deploy:update_code", "symlink:settings"
namespace :deploy do
desc "Restart Application"
task :restart do
run "touch #{current_path}/tmp/restart.txt"
end
[:start, :stop].each do |t|
desc "#{t} task is a no-op with mod_rails"
task t, :roles => :app do ; end
end
end
namespace :symlink do
desc "Make copy of database yaml"
task :settings do
run "ln -s #{shared_path}/settings.rb #{release_path}/settings.rb"
end
end
Jump to Line
Something went wrong with that request. Please try again.