Initialize port
This commit is contained in:
38
files/godit.in
Normal file
38
files/godit.in
Normal file
@ -0,0 +1,38 @@
|
||||
#!/bin/sh
|
||||
|
||||
# PROVIDE: godit
|
||||
# REQUIRE: audit
|
||||
# KEYWORD: shutdown
|
||||
#
|
||||
# Add the following to /etc/rc.conf[.local] to enable this service
|
||||
# godit_enable="YES"
|
||||
#
|
||||
|
||||
. /etc/rc.subr
|
||||
|
||||
: ${godit_enable=NO}
|
||||
: ${godit_extra_args=""}
|
||||
|
||||
name="godit"
|
||||
rcvar="godit_enable"
|
||||
pidfile=/var/run/godit.daemon.pid
|
||||
childpidfile=/var/run/godit.pid
|
||||
godit_current_file="/var/audit/current.godit"
|
||||
|
||||
load_rc_config ${name}
|
||||
|
||||
start_precmd="${name}_prestart"
|
||||
command="/usr/sbin/daemon"
|
||||
godit_command="%%PREFIX%%/bin/godit"
|
||||
command_args="-rP ${pidfile} -p ${childpidfile} -S -R 1 -T ${name} \
|
||||
${godit_command} -l ${godit_extra_args} -o ${godit_current_file} /dev/auditpipe"
|
||||
|
||||
extra_commands="reload"
|
||||
|
||||
godit_prestart()
|
||||
{
|
||||
install -d -m 0750 `dirname "${godit_current_file}"`
|
||||
}
|
||||
|
||||
run_rc_command "$1"
|
||||
|
||||
7
files/godit.newsyslog
Normal file
7
files/godit.newsyslog
Normal file
@ -0,0 +1,7 @@
|
||||
# configuration file for newsyslog for net-snmp
|
||||
#
|
||||
# see newsyslog.conf(5) for details
|
||||
#
|
||||
# logfilename [owner:group] mode count size when flags [/pid_file] [sig_num]
|
||||
/var/audit/current.godit 640 1 * @T00 R /var/run/godit.pid SIGUSR1
|
||||
|
||||
Reference in New Issue
Block a user