ports/dns/nsnotifyd/files/nsnotifyd.in
2021-04-06 16:31:13 +02:00

34 lines
661 B
Bash

#!/bin/sh
#
# Author: Mark Felder <feld@FreeBSD.org>
# PROVIDE: nsnotifyd
# REQUIRE: LOGIN
# KEYWORD: shutdown
# Add the following lines to /etc/rc.conf to enable nsnotifyd:
# nsnotifyd_enable="YES"
# nsnotifyd_flags="<set as needed>"
. /etc/rc.subr
name=nsnotifyd
rcvar=nsnotifyd_enable
load_rc_config $name
: ${nsnotifyd_enable:=NO}
command="/usr/local/bin/nsnotifyd"
start_precmd=precmd
precmd()
{
if [ "${nsnotifyd_flags}x" = "x" ]; then
echo "Please set your required service options via nsnotifyd_flags in /etc/rc.conf."
echo "Check the contents of man nsnotifyd for more details."
exit 1
fi
}
run_rc_command "$1"