diff --git a/entrypoint.sh.release b/entrypoint.sh.release index d8222305b..71d3a7cf2 100644 --- a/entrypoint.sh.release +++ b/entrypoint.sh.release @@ -1,7 +1,7 @@ #!/bin/sh grepzt() { - [ -f /var/lib/zerotier-one/zerotier-one.pid -a -n "$(cat /var/lib/zerotier-one/zerotier-one.pid)" -a -d "/proc/$(cat /var/lib/zerotier-one/zerotier-one.pid)" ] + [ -f /var/lib/zerotier-one/zerotier-one.pid -a -n "$(cat /var/lib/zerotier-one/zerotier-one.pid 2>/dev/null)" -a -d "/proc/$(cat /var/lib/zerotier-one/zerotier-one.pid 2>/dev/null)" ] return $? } @@ -34,7 +34,7 @@ mkztfile zerotier-one.port 0600 "9993" killzerotier() { echo "Killing zerotier" - kill $(cat /var/lib/zerotier-one/zerotier-one.pid) + kill $(cat /var/lib/zerotier-one/zerotier-one.pid 2>/dev/null) exit 0 }