mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-28 01:06:17 +00:00
83eb2c3700
literal name_enable wherever possible, and ${name}_enable when it's not, to prepare for the demise of set_rcvar(). In cases where I had to hand-edit unusual instances also modify formatting slightly to be more uniform (and in some cases, correct). This includes adding some $FreeBSD$ tags, and most importantly moving rcvar= to right after name= so it's clear that one is derived from the other.
34 lines
755 B
Bash
34 lines
755 B
Bash
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
# PROVIDE: quaqut
|
|
# REQUIRE: NETWORKING
|
|
#
|
|
# Add the following line to /etc/rc.conf[.local] to enable quaqut
|
|
#
|
|
# quaqut_enable (bool): Set to "NO" by default.
|
|
# Set it to "YES" to enable quaqut.
|
|
# quaqut_host (str): Server hostname.
|
|
# quaqut_logfile (str): Logfile name.
|
|
# quaqut_interval (number): Query interval duration.
|
|
# It must be a number between 10 and 9999.
|
|
#
|
|
|
|
. /etc/rc.subr
|
|
|
|
name="quaqut"
|
|
rcvar=quaqut_enable
|
|
|
|
load_rc_config $name
|
|
|
|
: ${quaqut_enable="NO"}
|
|
: ${quaqut_host="some.ut2004server.tld"}
|
|
: ${quaqut_logfile="/var/log/quaqut.log"}
|
|
: ${quaqut_interval="10"}
|
|
|
|
command="/usr/local/bin/quaqut"
|
|
command_args="-d ${quaqut_interval} ${quaqut_flags} ${quaqut_host} >> ${quaqut_logfile} &"
|
|
|
|
run_rc_command "$1"
|