correctly remove prometheus temp/lock file
This commit is contained in:
parent
b47c31e546
commit
c7615afb9a
1 changed files with 2 additions and 3 deletions
|
@ -18,8 +18,6 @@ case $1 in
|
||||||
|
|
||||||
;;
|
;;
|
||||||
prometheus)
|
prometheus)
|
||||||
rm -f /tmp/prometheus.pid
|
|
||||||
|
|
||||||
daemonize -c /srv \
|
daemonize -c /srv \
|
||||||
-p /tmp/prometheus.pid \
|
-p /tmp/prometheus.pid \
|
||||||
-l /tmp/prometheus.pid \
|
-l /tmp/prometheus.pid \
|
||||||
|
@ -28,7 +26,8 @@ case $1 in
|
||||||
;;
|
;;
|
||||||
|
|
||||||
prometheus-stop)
|
prometheus-stop)
|
||||||
cat /tmp/prometheus.pid | xargs -r kill
|
test ! -f /tmp/prometheus.pid || cat /tmp/prometheus.pid | xargs -r kill
|
||||||
|
rm -f /tmp/prometheus.pid
|
||||||
|
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue