log to syslog
This commit is contained in:
parent
5416ab7cba
commit
3fa2ef3b5d
1 changed files with 1 additions and 3 deletions
|
@ -3,14 +3,12 @@ set -e
|
||||||
|
|
||||||
dir=${DIR:-/srv}
|
dir=${DIR:-/srv}
|
||||||
pid=/run/mmmonit.pid
|
pid=/run/mmmonit.pid
|
||||||
# TODO: Log to syslog
|
|
||||||
log=${dir}/mmmonit.log
|
|
||||||
usr=${USER:-nobody}
|
usr=${USER:-nobody}
|
||||||
|
|
||||||
case $1 in
|
case $1 in
|
||||||
start)
|
start)
|
||||||
chown -R ${usr}:${usr} ${dir}
|
chown -R ${usr}:${usr} ${dir}
|
||||||
daemonize -a -e ${log} -o ${log} -c ${dir} -p ${pid} -l ${pid} -u ${usr} /usr/bin/mmmonit -b :: -p 3000
|
daemonize -c ${dir} -p ${pid} -l ${pid} -u ${usr} /usr/local/bin/syslogize /usr/bin/mmmonit -b :: -p 3000
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
test -f ${pid} || exit 0
|
test -f ${pid} || exit 0
|
||||||
|
|
Loading…
Reference in a new issue