Last active
December 10, 2015 22:28
-
-
Save bsphere/4502175 to your computer and use it in GitHub Desktop.
Upstart config for Node.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/etc/init/myapp.conf | |
description "MyApp Node.js" | |
author "[email protected]" | |
start on (local-filesystems and net-device-up IFACE=eth0) | |
stop on shutdown | |
respawn | |
respawn limit 5 60 | |
script | |
cd /home/ubuntu/myapp | |
exec sudo -u ubuntu NODE_ENV=production /usr/bin/node /home/ubuntu/myapp/server.js >> /home/ubuntu/myapp/log/server.log 2>&1 | |
end script |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment