File: netdaemon

package info (click to toggle)
netapplet 1.0.8-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 1,204 kB
  • ctags: 281
  • sloc: sh: 3,441; ansic: 3,288; makefile: 126
file content (47 lines) | stat: -rwxr-xr-x 997 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#! /bin/sh
### BEGIN INIT INFO
# Provides:       netdaemon
# Required-Start: $network
# Default-Start:  3 4 5
# Default-Stop:   0 1 2 6
# Description: netdaemon, the network control and switching daemon
### END INIT INFO

NETDAEMON_BIN=/opt/gnome/bin/netdaemon
test -x $NETDAEMON_BIN || exit 5

. /etc/rc.status
rc_reset

case "$1" in
    start)
        echo -n "Starting the netdaemon"
        startproc $NETDAEMON_BIN
	rc_status -v
        ;;
    stop)
        echo -n "Shutting down the netdaemon"
        killproc -TERM $NETDAEMON_BIN
	rc_status -v
        ;;
    restart)
        $0 stop
        $0 start
	rc_status
        ;;
    force-reload|reload)
        echo -n "Reloading the netdaemon"
        killproc -HUP $NETDAEMON_BIN
	rc_status -v
        ;;
    status)
        echo -n "Checking for the netdaemon: "
        checkproc $NETDAEMON_BIN
        rc_status -v
        ;;
    *)
        echo "Usage: $0 {start|stop|status|restart|force-reload|reload}"
        exit 1
        ;;
esac