Skip to content

Instantly share code, notes, and snippets.

@CamonZ
Created November 10, 2010 00:20
Show Gist options
  • Select an option

  • Save CamonZ/670106 to your computer and use it in GitHub Desktop.

Select an option

Save CamonZ/670106 to your computer and use it in GitHub Desktop.
namespace :deploy do
task :start do; end
task :stop do; end
desc "restart passenger server"
task :restart, :roles => :app, :except => { :no_release => true } do
run "#{try_sudo} touch #{File.join(current_path,'tmp','restart.txt')}"
end
desc "Update the crontab file"
task :update_crontab, :roles => :db do
run "cd #{release_path} && whenever --update-crontab #{application}"
end
end
after "deploy:symlink", "deploy:update_crontab"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment