Created
December 15, 2011 06:33
-
-
Save codebrew/1480072 to your computer and use it in GitHub Desktop.
upstart script to run a master hookio-server
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
# Ubuntu upstart file at /etc/init/hookio-server.conf | |
author "Ryan Fitzgerald <[email protected]>" | |
env DIR=/var/lib/hookio-server/ | |
env DAEMON=/usr/local/bin/hookio | |
env LOG_DIR=/var/log/hookio | |
env NODE_ENV=production | |
pre-start script | |
mkdir -p $DIR | |
mkdir -p $LOG_DIR | |
end script | |
start on runlevel [2345] | |
stop on runlevel [06] | |
respawn | |
script | |
exec start-stop-daemon --start --quiet --chdir $DIR --exec $DAEMON >> $LOG_DIR/hookio-server.log 2>&1 | |
end script |
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
author "Ryan Fitzgerald <[email protected]>" | |
env DIR=/home/ubuntu/apps/stockroom/ | |
env DAEMON=/home/ubuntu/apps/stockroom/bin/stockroom | |
env LOG_DIR=/var/log/stockroom | |
env NODE_ENV=production | |
pre-start script | |
mkdir -p $DIR | |
mkdir -p $LOG_DIR | |
end script | |
start on started hookio-server | |
respawn | |
script | |
exec start-stop-daemon --start --quiet --chdir $DIR --exec $DAEMON >> $LOG_DIR/stockroom.log 2>&1 | |
end script |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment