tunnel, add green light output for loop.

This commit is contained in:
me committed 2026-11-04 19:50:58 -07:00
1 parent 768cabfe45
commit bbffe8c69a
1 file changed
+5 -2
+5 -2
View File
@@ -63,12 +63,15 @@
( (
while true; do while true; do
sleep 300 sleep 300
nc -zv {{ tunnel_remote_host }} {{ tunnel_remote_port }} >/dev/null 2>&1 echo -n "RUN-LOOP: "
nc -zv {{ tunnel_remote_host }} {{ tunnel_remote_port }}
status="$?" status="$?"
echo "RUN-LOOP: Port check returned ${status}."
if [[ "$status" != 0 ]]; then if [[ "$status" != 0 ]]; then
echo "RUN: Port check returned $status, restarting service." echo "RUN-LOOP: Restarting service."
sv restart {{ tunnel_service_name }} sv restart {{ tunnel_service_name }}
fi fi
echo "RUN-LOOP: Going back to sleep."
done done
) & ) &