blob: f1d8e6e2d158d1e8a12b3a5900d45e35f0ead995 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
#!/sbin/runscript
# Distributed under the terms of the GNU General Public License v2
PERL="$( type -pf perl )"
NAME=heatmiser_daemon.pl
DAEMON=/usr/libexec/heatmiser/$NAME
DAEMON_ARGS=""
PIDFILE=/var/run/$NAME.pid
depend() {
need mysql
}
start() {
ebegin "Starting Heatmiser Logger"
start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $PERL -- $DAEMON $DAEMON_ARGS
eend $? "Unable to start Logging Daemon"
}
stop() {
ebegin "Stopping Heatmiser Logger"
start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --interpreted --exec $PERL $DAEMON
eend $? "Unable to stop Logging Daemon"
}
|