blob: 892eac6f9a8fb368618cfa818d9e63675a948b58 (
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
25
26
27
28
29
30
31
32
|
#!/bin/sh
# PROVIDE: rrdbot
# REQUIRE: LOGIN
# KEYWORD: shutdown
#
# Add the following line to /etc/rc.conf to enable rrdbot:
# rrdbot_enable (bool): Set to "NO" by default.
# Set it to "YES" to start rrdbotd.
# rrdbot_pidfile (str): pidfile location for rrdbotd.
# Defaults to "/var/run/rrdbotd.pid".
# rrdbot_flags (str): Custom command-line flags to be passed
# to rrdbotd (default: none).
#
. /etc/rc.subr
name="rrdbot"
rcvar=rrdbot_enable
load_rc_config $name
: ${rrdbot_enable="NO"}
: ${rrdbot_pidfile="/var/run/rrdbotd.pid"}
pidfile="${rrdbot_pidfile}"
command="%%PREFIX%%/sbin/rrdbotd"
command_args="-p ${rrdbot_pidfile}"
run_rc_command "$1"
|