Created
December 19, 2012 06:34
-
-
Save ijin/4334845 to your computer and use it in GitHub Desktop.
webdis upstart
This file contains hidden or 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
# webdis | |
description "webdis control" | |
author "Michael H. Oshita" | |
#start on (local-filesystems and net-device-up IFACE=eth0) | |
start on redis | |
stop on shutdown | |
# monit does this | |
#respawn # restart when job dies | |
#respawn limit 5 60 # give up restart after 5 respawns in 60 seconds | |
script | |
APP=/usr/local/bin/webdis | |
USER=redis | |
CONFIG=/etc/redis/webdis.json | |
PIDFILE=/var/run/webdis.pid | |
ERROR_LOG=/var/log/redis/webdis_error.log | |
ulimit -n 10000 | |
start-stop-daemon --start -c $USER -m -p $PIDFILE --exec $APP -- $CONFIG 2>> $ERROR_LOG | |
end script |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment