#!/bin/sh ############################################################## # # mu-conference -- script to start Mu-Conference. # ############################################################# DAEMON=/usr/local/bin/mu-conference CONF=/etc/jabber/muc-jcr.xml NAME=mu-conference USER=ejabberd ############################################################# if [ "`/usr/bin/whoami`" != "$USER" ]; then echo "You need to be" $USER "user to run this script." exit 1 fi case "$1" in debug) test -f $DAEMON -a -f $CONF || exit 0 echo "Starting $NAME in debugging mode." $DAEMON -B -d 255 -c $CONF & ;; start) test -f $DAEMON -a -f $CONF || exit 0 echo "Starting $NAME." $DAEMON -B -c $CONF & ;; stop) echo "Stopping $NAME." killall $NAME & ;; restart|reload) $0 stop sleep 3 $0 start ;; *) echo "Usage: $0 {debug|start|stop|restart}" exit 1 esac