2 # Copyright 1999-2011 Gentoo Foundation
3 # Distributed under the terms of the GNU General Public License v2
11 out=`(/usr/sbin/siprouter -f ${CONFIGFILE} -c > /dev/null || true) 2>&1`
12 echo "$out" | grep -q 'config file ok, exiting...'
13 if [ "$?" == 1 ]; then
14 echo -e "There are errors in the configuration. Please fix them first"
21 check_config || return 1
22 ebegin "Starting siprouter"
23 start-stop-daemon --start --quiet --pidfile /var/run/siprouter.pid \
24 --exec /usr/sbin/siprouter -- -P /var/run/siprouter.pid \
30 ebegin "Stopping siprouter"
31 start-stop-daemon --stop --quiet --pidfile /var/run/siprouter.pid