void-packages/templates/metalog/files/metalog.rc

29 lines
486 B
Plaintext

#!/sbin/runscript
extra_commands="buffer unbuffer"
command=/usr/sbin/metalog
pidfile=${metalog_pid:-/var/run/metalog.pid}
command_args="$metalog_flags --daemonize --pidfile $pidfile"
depend()
{
provide logger
need localmount
use clock hostname
after bootmisc
}
buffer()
{
ebegin "Enabling log buffering"
start-stop-daemon --signal USR2 --pidfile $pidfile
eend $?
}
unbuffer()
{
ebegin "Disabling log buffering"
start-stop-daemon --signal USR1 --pidfile $pidfile
eend $?
}