mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-24 09:25:01 +00:00
- Allow user to change parameters of start syslog-ng via vars rc.d script [1]
- Allow user to purge klog(9) via vars rc.d script [2] PR: ports/98287 [1] and [2] Submitted by: Pavel Volkov [1], Brian A. Seklecki [2]
This commit is contained in:
parent
0d023c33e2
commit
574c1df44c
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=178755
@ -12,8 +12,12 @@
|
||||
# to enable this service:
|
||||
#
|
||||
#syslog_ng_enable="YES"
|
||||
#syslog_ng_config="-u daemon"
|
||||
#syslog_ng_pid="/var/run/syslog-ng.pid"
|
||||
#
|
||||
|
||||
syslog_ng_purgeklog=${syslog_ng_purgeklog-"NO"}
|
||||
|
||||
. %%RC_SUBR%%
|
||||
|
||||
name=syslog_ng
|
||||
@ -21,13 +25,19 @@ rcvar=`set_rcvar`
|
||||
|
||||
command=%%PREFIX%%/sbin/syslog-ng
|
||||
required_files=%%PREFIX%%/etc/syslog-ng/syslog-ng.conf
|
||||
pidfile=/var/run/syslog.pid
|
||||
extra_commands=reload
|
||||
|
||||
if checkyesno syslog_ng_purgeklog; then
|
||||
start_precmd="echo \"Purging klog(9)\" && sysctl -w kern.msgbuf_clear=1 $start_precmd";
|
||||
fi
|
||||
|
||||
stop_postcmd=stop_postcmd
|
||||
|
||||
load_rc_config $name
|
||||
|
||||
: ${syslog_ng_enable:="NO"}
|
||||
pidfile=${syslog_ng_pid:-"/var/run/syslog.pid"}
|
||||
command_args="-p ${pidfile} ${syslog_ng_config}"
|
||||
|
||||
stop_postcmd() {
|
||||
rm -f $pidfile
|
||||
|
@ -12,8 +12,12 @@
|
||||
# to enable this service:
|
||||
#
|
||||
#syslog_ng_enable="YES"
|
||||
#syslog_ng_config="-u daemon"
|
||||
#syslog_ng_pid="/var/run/syslog-ng.pid"
|
||||
#
|
||||
|
||||
syslog_ng_purgeklog=${syslog_ng_purgeklog-"NO"}
|
||||
|
||||
. %%RC_SUBR%%
|
||||
|
||||
name=syslog_ng
|
||||
@ -21,13 +25,19 @@ rcvar=`set_rcvar`
|
||||
|
||||
command=%%PREFIX%%/sbin/syslog-ng
|
||||
required_files=%%PREFIX%%/etc/syslog-ng/syslog-ng.conf
|
||||
pidfile=/var/run/syslog.pid
|
||||
extra_commands=reload
|
||||
|
||||
if checkyesno syslog_ng_purgeklog; then
|
||||
start_precmd="echo \"Purging klog(9)\" && sysctl -w kern.msgbuf_clear=1 $start_precmd";
|
||||
fi
|
||||
|
||||
stop_postcmd=stop_postcmd
|
||||
|
||||
load_rc_config $name
|
||||
|
||||
: ${syslog_ng_enable:="NO"}
|
||||
pidfile=${syslog_ng_pid:-"/var/run/syslog.pid"}
|
||||
command_args="-p ${pidfile} ${syslog_ng_config}"
|
||||
|
||||
stop_postcmd() {
|
||||
rm -f $pidfile
|
||||
|
Loading…
Reference in New Issue
Block a user