Created
September 23, 2009 14:06
-
-
Save documentcloud/192027 to your computer and use it in GitHub Desktop.
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
#! /bin/sh | |
### BEGIN INIT INFO | |
# Provides: cloud-crowd | |
# Required-Start: $all | |
# Required-Stop: $all | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: S 0 1 6 | |
# Short-Description: starts a cloud-crowd node | |
# Description: starts a cloud-crowd node using start-stop-daemon | |
### END INIT INFO | |
PATH=/usr/local/bin:/usr/bin:$PATH | |
DAEMON=crowd | |
CONFIG_PATH=</path/to/your/config/folder> | |
test -x $DAEMON || exit 0 | |
case "$1" in | |
start) | |
$DAEMON -d -c $CONFIG_PATH node start | |
;; | |
stop) | |
$DAEMON -d -c $CONFIG_PATH node stop | |
;; | |
restart) | |
$DAEMON -d -c $CONFIG_PATH node restart | |
;; | |
*) | |
echo "Usage: $DAEMON -d node [start|stop|restart]" >&2 | |
exit 3 | |
;; | |
esac | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment