From: Michael Tremer Date: Sun, 6 Feb 2011 18:55:23 +0000 (+0100) Subject: icecc: Update of initscript. X-Git-Tag: v2.9-core47~9^2~2 X-Git-Url: http://git.ipfire.org/?p=ipfire-2.x.git;a=commitdiff_plain;h=c74f6bce72cad9e2599416d9602dd426d864f1d4 icecc: Update of initscript. --- diff --git a/src/initscripts/init.d/icecream b/src/initscripts/init.d/icecream index 6ce466003d..f8fa4e3330 100644 --- a/src/initscripts/init.d/icecream +++ b/src/initscripts/init.d/icecream @@ -15,24 +15,32 @@ . /etc/sysconfig/rc . ${rc_functions} -SCHEDULER=minerva.ipfire.org +#SCHEDULER=minerva.ipfire.org +ENABLE_SCHEDULER=on JOBS=8 -PORT=10244 case "${1}" in start) boot_mesg "Starting Icecream Daemon..." - /opt/icecream/sbin/iceccd -d -s ${SCHEDULER} -m ${JOBS} -p ${PORT} + ARGS="-d -m ${JOBS}" + if [ -n "${SCHEDULER}" ]; then + ARGS="${ARGS} -s ${SCHEDULER}" + fi + /opt/icecream/sbin/iceccd ${ARGS} evaluate_retval - if ! grep -q "${PORT}" /var/ipfire/xtaccess/config ; then - echo "tcp,0.0.0.0/0,${PORT},on,0.0.0.0,Icecream" >> /var/ipfire/xtaccess/config - /usr/local/bin/setxtaccess + + if [ "${ENABLE_SCHEDULER}" = "on" ]; then + /opt/icecream/sbin/icecc-scheduler -d fi ;; stop) boot_mesg "Stopping Icecream Daemon..." killproc /opt/icecream/sbin/iceccd + + if [ "${ENABLE_SCHEDULER}" = "on" ]; then + killproc /opt/icecream/sbin/icecc-scheduler + fi ;; restart)