X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Fchatty;a=blobdiff_plain;f=extra%2Fcometd%2Fdaemoncontroller.dist;fp=extra%2Fcometd%2Fdaemoncontroller.dist;h=5370a26904945e507dcf2ff1481f8930092887fc;hp=0000000000000000000000000000000000000000;hb=100d54b49cab3783276b3a470fffa5e509929daf;hpb=06da6ad7294f8293cfe3a5e77e0f676d2884cd79 diff --git a/extra/cometd/daemoncontroller.dist b/extra/cometd/daemoncontroller.dist new file mode 100644 index 0000000..5370a26 --- /dev/null +++ b/extra/cometd/daemoncontroller.dist @@ -0,0 +1,29 @@ +#!/bin/sh +# description: Runs meteord +# chkconfig: 2345 99 00 + +# Source function library. +. /etc/init.d/functions + +case "$1" in +'start') +echo -n "Starting Meteord: " +echo 65535 > /proc/sys/fs/file-max +ulimit -n 65535 +cd /usr/local/meteor +sudo -u meteor ./meteord >/var/log/meteord 2>&1 & +echo +;; +'stop') +echo -n "Stopping Meteord: " +killall meteord && success || failure +;; +'reload') +echo -n "Reloading Meteord configuration: " +killall -s SIGHUP meteord && success || failure +;; +*) +echo "Usage: $0 { start | stop | reload }" +;; +esac +exit 0