3 # cr Conference Room IRC Daemon
7 # description: Conference Room is a IRC Daemon
11 # Source function library
12 . /etc/rc.d/init.d/functions
15 . /etc/sysconfig/network
19 # Get service config - may override defaults
20 [ -f /etc/sysconfig/cr ] && . /etc/sysconfig/cr
22 # Check that networking is up.
23 if is_yes "${NETWORKING}"; then
24 if [ ! -f /var/lock/subsys/network -a "$1" != stop -a "$1" != status ]; then
33 # Check if the service is already running?
34 if [ ! -f /var/lock/subsys/cr ]; then
35 msg_starting "Conference Room IRC Daemon"; busy
36 start-stop-daemon --start \
38 --pidfile /var/lib/cr/CRServices.pid \
39 --exec /usr/lib/cr/programs/launcher \
41 -- /var/lib/cr $SERVICES
44 if [ $RETVAL -eq 0 ]; then
46 touch /var/lock/subsys/cr
51 msg_already_running "Conference Room IRC Daemon"
56 if [ -f /var/lock/subsys/cr ]; then
58 msg_stopping "Conference Room IRC Daemon"
59 start-stop-daemon --stop --oknodo --pidfile /var/lib/cr/CRServices.pid && ok || fail
60 rm -f /var/lock/subsys/cr
62 msg_not_running "Conference Room IRC Daemon"
67 if [ -f /var/lock/subsys/cr ]; then
71 msg_not_running "Conference Room IRC Daemon"
77 # See how we were called.
100 msg_usage "$0 {start|stop|restart|try-restart|force-reload|status}"