freebsd-ports/net-mgmt/argus-monitor/files/argusd.in
Olli Hauer 8003f3f40e - rewrite for options NG framework
- /USE_APACHE/USE_APACHE_RUN/
- make usage of ETCDIR, WWWDIR instead PREFIX/(etc|www)/PORTNAME
- add pkg-install script to adjust directory file mode,
  else they differ when installed by package
- use @dirrmtry to preserve existing stats ...
- bump PORTREVISION

PR:             171475
Submitted by:   ohauer
Approved by:    (old) maintainer timeout (port was moved today to ports@)
2012-10-07 18:44:44 +00:00

37 lines
738 B
Bash

#!/bin/sh
# PROVIDE: argusd
#
# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
# to enable this service:
#
# argusd_enable (bool): Set to NO by default.
# Set it to YES to enable argusd
#
. /etc/rc.subr
name="argusd"
rcvar=argusd_enable
command=%%PREFIX%%/sbin/${name}
# pidfile=/var/run/${name}.pid
required_files="
%%ETCDIR%%/log \
%%ETCDIR%%/notno \
%%ETCDIR%%/config \
%%ETCDIR%%/users"
stop_cmd="%%PREFIX%%/sbin/argusctl shutdown reason=\"rc.argusd stop\""
start_precmd="/usr/bin/touch %%ETCDIR%%/log"
extra_commands="console hup"
console_cmd="%%PREFIX%%/sbin/argusctl -k console"
hup_cmd="%%PREFIX%%/sbin/argusctl -k hup"
load_rc_config $name
: ${argusd_enable="NO"}
run_rc_command "$1"