Skip to content

Instantly share code, notes, and snippets.

@ordoghl
Last active August 1, 2017 08:47
Show Gist options
  • Save ordoghl/5883883 to your computer and use it in GitHub Desktop.
Save ordoghl/5883883 to your computer and use it in GitHub Desktop.
Ubuntu upstart job for Puma w/ rbenv and application deployed to appuser home directory.
# /etc/init/puma.conf - Puma config
description "Puma App Service"
start on (local-filesystems and net-device-up IFACE=lo and runlevel [2345])
stop on (runlevel [!2345])
setuid appuser
setgid appuser
respawn
respawn limit 3 30
env HOME=/home/appuser
env PATH=/home/appuser/.rbenv/shims:/home/appuser/.rbenv/bin:/usr/local/bin:/usr/bin:/bin
chdir /home/appuser/app/current
exec /home/appuser/.rbenv/shims/puma -C /home/appuser/app/current/config/puma.rb
@toppa
Copy link

toppa commented Apr 19, 2016

Thanks very much for this!

@GregIngelmo
Copy link

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment