restructure prober code a little bit

This commit is contained in:
2025-02-20 15:15:43 +02:00
parent e4793cc90c
commit 3ad5c9a641

View File

@@ -17,20 +17,14 @@ let
set -x set -x
while true; do while true; do
FAILED=0 FAILED=0
for input in \
vno4-dome-panorama-orig \ for input in vno4-dome-{panorama,ptz}-{orig,high,low}; do
vno4-dome-panorama-high \
vno4-dome-panorama-low \
vno4-dome-ptz-orig \
vno4-dome-ptz-high \
vno4-dome-ptz-low; do
timeout 30s \ timeout 30s \
ffprobe -hide_banner "rtsp://localhost:8554/''${input}" || \ ffprobe -hide_banner "rtsp://localhost:8554/''${input}" || FAILED=1
FAILED=1
done done
if [[ "$FAILED" == 1 ]]; then
systemctl restart --no-block go2rtc.service [[ "$FAILED" == 1 ]] && systemctl restart --no-block go2rtc.service
fi
sleep 5m sleep 5m
done done
''; '';