Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash
#
# Rails console script that can be run on AWS Elastic Beanstalk.
#
# Run this script from the app dir (/var/app/current) as root (sudo script/aws-console)
#
set -xe
EB_SCRIPT_DIR=$(/opt/elasticbeanstalk/bin/get-config container -k script_dir)
@banta
banta / deploy.rb
Created July 27, 2012 12:50 — forked from thbar/deploy.rb
Resque + god + capistrano recipe
# note - you may need to split into a before-deploy (stop) and after-deploy (start) depending on your setup
desc "Hot-reload God configuration for the Resque worker"
deploy.task :reload_god_config do
sudo "god stop resque"
sudo "god load #{File.join deploy_to, 'current', 'config', 'resque.god'}"
sudo "god start resque"
end
after 'deploy:update_code', 'deploy:update_shared_symlinks'