summaryrefslogtreecommitdiff
path: root/net/nncp/files/nncp-caller.in
blob: 3ae65fb03ee2547750500efb63eff5a60d596ca1 (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
#!/bin/sh

# PROVIDE: nncp-caller
# REQUIRE: DAEMON NETWORKING FILESYSTEMS
# KEYWORD: shutdown
#
# Add these lines to /etc/rc.conf.local or /etc/rc.conf
# to enable this service:
#
# nncp_caller_enable (bool):	Set to NO by default.
#				Set it to YES to enable nncp-caller.
# nncp_caller_config (path):	Set to %%PREFIX%%/etc/nncp.hjson by default.

. /etc/rc.subr

name=nncp_caller
rcvar=nncp_caller_enable

load_rc_config $name

: ${nncp_caller_enable:="NO"}
: ${nncp_caller_config="%%PREFIX%%/etc/nncp.hjson"}

command=%%PREFIX%%/bin/nncp-caller
command_args="-quiet -cfg $nncp_caller_config &"

run_rc_command "$1"