]> git.meshlink.io Git - catta/blob - initscript/suse/avahi-dnsconfd.in
e633b8d16cd168bab3a228fb47473966c6c73b2e
[catta] / initscript / suse / avahi-dnsconfd.in
1 #! /bin/sh
2 ### BEGIN INIT INFO
3 # Provides:          avahi-dnsconfd
4 # Required-Start:    $remote_fs avahi
5 # Default-Start:     3 5
6 # Default-Stop:
7 # Short-Description: ZeroConf daemon
8 # Description:       Avahi, a ZeroConf daemon for mDNS and service registration
9 ### END INIT INFO
10
11 AVAHI_BIN=@sbindir@/avahi-dnsconfd
12 test -x $AVAHI_BIN || exit 5
13
14 . /etc/rc.status
15 rc_reset
16
17 case "$1" in
18         start)
19                 echo -n "Starting Avahi DNS Configuration daemon "
20                 $AVAHI_BIN -D
21                 rc_status -v
22                 ;;
23         stop)
24                 echo -n "Shutting down Avahi DNS Configuration daemon "
25                 $AVAHI_BIN -k 2>/dev/null || /bin/true
26                 rc_status -v
27                 ;;
28         restart)
29                 $0 stop
30                 $0 start
31                 rc_status
32                 ;;
33         force-reload|reload)
34                 echo -n "Reloading Avahi DNS Configuration daemon "
35                 $AVAHI_BIN -r
36                 rc_status -v
37                 ;;
38         status)
39                 echo -n "Checking for Avahi DNS Configuration daemon: "
40                 $AVAHI_BIN -c
41                 rc_status -v
42                 ;;
43         *)
44                 echo "Usage: $0 {start|stop|status|restart|force-reload|reload}"
45                 exit 1
46                 ;;
47 esac