summaryrefslogtreecommitdiffabout
path: root/debian/dudki.init
Unidiff
Diffstat (limited to 'debian/dudki.init') (more/less context) (ignore whitespace changes)
-rw-r--r--debian/dudki.init58
1 files changed, 58 insertions, 0 deletions
diff --git a/debian/dudki.init b/debian/dudki.init
new file mode 100644
index 0000000..aaab403
--- a/dev/null
+++ b/debian/dudki.init
@@ -0,0 +1,58 @@
1#! /bin/sh
2#
3# dudki dudki startup script
4#
5
6### BEGIN INIT INFO
7# Provides: dudki
8# Required-Start: $local_fs $remote_fs $syslog
9# Required-Stop: $local_fs $remote_fs $syslog
10# Should-Start:
11# Should-Stop:
12# Default-Start: S 2 3 4 5
13# Default-Stop: 0 1 6
14# Short-Description: a process maintenance daemon
15### END INIT INFO
16
17# Edit /etc/default/dudki to change options
18DUDKI_CONF=/etc/dudki.conf
19
20PATH=/sbin:/bin:/usr/sbin:/usr/bin
21DUDKI=/usr/sbin/dudki
22NAME=dudki
23DESC="process maintenance daemon"
24
25[ -x $DUDKI ] || exit 0
26
27. /lib/lsb/init-functions
28
29[ -f /etc/default/$NAME ] && . /etc/default/$NAME
30
31case "$1" in
32 start)
33 log_daemon_msg "Starting $DESC $NAME"
34 $DUDKI -e
35 log_end_msg $?
36 ;;
37 stop)
38 log_daemon_msg "Stopping $DESC $NAME"
39 $DUDKI -k
40 log_end_msg $?
41 ;;
42 reload)
43 log_daemon_msg "Reloading $NAME configuration"
44 $DUDKI -r
45 log_end_msg $?
46 ;;
47 restart|force-reload)
48 $0 stop
49 sleep 1
50 $0 start
51 ;;
52 *)
53 echo "Usage: /etc/init.d/$NAME {start|stop|restart|reload|force-reload}" >&2
54 exit 1
55 ;;
56esac
57
58exit 0