# TODO: migrate to capistrano3 bundler integration require 'bundler/capistrano' set :bundle_dir, '' set :bundle_flags, '--quiet' set :bundle_without, [] set :application, "lycan" set :repository, "https://tangled.sh/@mackuba.eu/lycan" set :scm, :git set :keep_releases, 10 set :use_sudo, false set :deploy_to, "/var/www/lycan" set :deploy_via, :remote_cache set :migrate_env, "RACK_ENV=production" set :public_children, [] set :shared_children, ['log', 'tmp/pids'] server "lycan.feeds.blue", :app, :web, :db, :primary => true before 'bundle:install', 'deploy:set_bundler_options' after 'deploy', 'deploy:cleanup' after 'deploy:migrations', 'deploy:cleanup' after 'deploy:update_code', 'deploy:link_shared' namespace :deploy do task :restart, :roles => :web do run "touch #{current_path}/tmp/restart.txt" end task :set_bundler_options do run "cd #{release_path} && bundle config set --local deployment 'true'" run "cd #{release_path} && bundle config set --local path '#{shared_path}/bundle'" run "cd #{release_path} && bundle config set --local without 'development test'" end task :link_shared do run "ln -s #{shared_path}/env #{release_path}/.env" end end