Skip to content

Instantly share code, notes, and snippets.

@jlebrech
Created March 30, 2012 11:58
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jlebrech/2251057 to your computer and use it in GitHub Desktop.
Save jlebrech/2251057 to your computer and use it in GitHub Desktop.
NGINX+RVM+UNICORN stack commands
echo precompile assets for production
rvmsudo RAILS_ENV=production bundle exec rake assets:precompile
echo restart unicorn
sudo kill `cat unicorn.pid`
echo start unicorn as production
rvmsudo unicorn_rails -c config/unicorn.rb -D --env production
echo restart nginx
killall nginx
sudo /etc/init.d/nginx restart
mysqldump -u root -p --databases development > bigdump.sql
mysql -u root -p development < bigdump.sql
rake incoming_mail:... RAILS_ENV=production
tmux: ctrl-b d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment