3 # original Author: Wilfried Goesgens <citadel@outgesourced.org>
4 # adapted for Gentoo: the_mgt <themgt@mail.ru>
12 RUNDIR="/var/run/citadel"
13 DAEMON="/usr/sbin/citserver"
14 PIDFILE="${RUNDIR}/citadel.pid"
15 SENDCOMMAND="/usr/sbin/sendcommand"
17 # Exit if the package is not installed
18 [ -x "$DAEMON" ] || exit 0
21 ebegin "Starting citserver"
22 start-stop-daemon --start --exec /usr/sbin/citserver -- ${CITSERVER_OPTS}
27 ebegin "Stopping citserver"
28 ${SENDCOMMAND} DOWN &>/dev/null
33 ebegin "Restarting citserver"
34 #sleep command mandatory due to long shutdown time!
35 svc_stop && sleep 3 && svc_start
36 eend $? "Failed to restart Citadel"