File rcscript of Package novars

#! /bin/sh
#
# System startup script for the NovaRS
#
### BEGIN INIT INFO
# Provides:          novars
# Required-Start:    $network
# Should-Start:
# Required-Stop:     $network
# Should-Stop:
# Default-Start:     3 5
# Default-Stop:      0 1 2 6
# Short-Description: NovaRS
# Description:       Start the NovaRS daemon
### END INIT INFO

NOVARS=/usr/sbin/NovaRS
test -x $NOVARS || exit 5

NOVARS_CONFIG=/etc/NovaRS/NovaRS.config
test -f $NOVARS_CONFIG || exit 6


# Source SuSE config
. /etc/rc.status

rc_reset
case "$1" in
    start)
        b=`date +%Y-%m-%dT%H:%M`
        echo -n "Starting GNSS data storing program"
        startproc -f $NOVARS 2>/dev/null >/dev/null
        rc_status -v
        ;;
    stop)
        echo -n "Shutting down GNSS data storing program"
        killproc -TERM $NOVARS
        rc_status -v
        ;;
    try-restart)
        $0 status >/dev/null && $0 restart
        rc_status
        ;;
    restart)
        $0 stop
        $0 start
        rc_status
        ;;
    force-reload)
        $0 try-restart
        rc_status
        ;;
    reload)
        $0 try-restart
        rc_status
        ;;
    status)
        echo -n "Checking for NovaRS service"
        checkproc $NOVARS
        rc_status -v
        ;;
    *)
        echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload}"
        exit 1
        ;;
esac
rc_exit
openSUSE Build Service is sponsored by