blob: 3d3486c661d8e3ead4c41639d6b4883ae3f030f4 (
plain) (
blame)
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
|
#!/bin/sh
#
# $FreeBSD$
#
# PROVIDE: watchd
# REQUIRE: DAEMON
# KEYWORD: shutdown
#
# Add the following line to /etc/rc.conf[.local] to enable watchd
#
# watchd_enable (bool): Set to "NO" by default.
# Set it to "YES" to enable watchd.
. /etc/rc.subr
name="watchd"
rcvar=${name}_enable
load_rc_config $name
: ${watchd_enable="NO"}
: ${watchd_config="%%PREFIX%%/etc/watchd.conf"}
: ${watchd_log="/var/log/watchd.log"}
command="%%PREFIX%%/bin/watchd"
command_args="${watchd_config} >> ${watchd_log}"
required_files="${watchd_config}"
run_rc_command "$1"
|