diff --git a/files/bashscripts/proxyserver/root/check-wireguard.sh b/files/bashscripts/proxyserver/root/check-wireguard.sh index 2ce4595..d08403b 100644 --- a/files/bashscripts/proxyserver/root/check-wireguard.sh +++ b/files/bashscripts/proxyserver/root/check-wireguard.sh @@ -9,13 +9,13 @@ while [[ $tries -lt 3 ]] do if $PING -c 1 10.0.10.1 then - echo "wg works" && curl -fsS -m 10 --retry 5 -o /dev/null http://192.168.1.4:8000/ping/12b1795f-a72a-479b-845b-f2576e8a546d - exit 0 + echo "wg works" && curl -fsS -m 10 --retry 5 -o /dev/null https://uptimekuma.akanealw.com/api/push/C6kilkNqUv?status=up&msg=OK&ping= + exit 0 fi echo "wg fail" tries=$((tries+1)) done -echo "wg failed 3 times - restarting tunnel" && curl -fsS -m 10 --retry 5 -o /dev/null http://192.168.1.4:8000/ping/12b1795f-a72a-479b-845b-f2576e8a546d/fail +echo "wg failed 3 times - restarting tunnel" && curl -fsS -m 10 --retry 5 -o /dev/null https://uptimekuma.akanealw.com/api/push/C6kilkNqUv?status=down&msg=OK&ping= ## DEBIAN -$SERVICE wg-quick@wg1 restart +$SERVICE wg-quick@wg1 restart && curl -fsS -m 10 --retry 5 -o /dev/null https://uptimekuma.akanealw.com/api/push/C6kilkNqUv?status=up&msg=OK&ping=