freebsd-ports/net/rwhoisd/files/rwhoisd.in
Doug Barton 1d6b4b3f91 Begin the process of deprecating sysutils/rc_subr by
s#. %%RC_SUBR%%#. /etc/rc.subr#
2010-03-27 00:15:24 +00:00

31 lines
669 B
Bash

#!/bin/sh
# PROVIDE: rwhoisd
# REQUIRE: LOGIN
#
# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
# to enable this service:
#
# rwhoisd_enable (bool): Set to NO by default.
# Set it to YES to enable rwhoisd.
# rwhoisd_config (path): Set to %%PREFIX%%/etc/rwhoisd/rwhoisd.conf
# by default.
#
. /etc/rc.subr
name="rwhoisd"
rcvar=${name}_enable
command=%%PREFIX%%/sbin/${name}
pidfile=${rwhoisd_pidfile}
load_rc_config $name
: ${rwhoisd_enable="NO"}
: ${rwhoisd_config="%%PREFIX%%/etc/rwhoisd/rwhoisd.conf"}
: ${rwhoisd_pidfile="/var/run/${name}/${name}.pid"}
command_args="-d -c $rwhoisd_config"
run_rc_command "$1"