Auto-update: Mon Sep 23 13:17:54 PDT 2024

This commit is contained in:
sanj 2024-09-23 13:17:54 -07:00
parent 38e9aaa26e
commit f17849d308
2 changed files with 2 additions and 5 deletions

BIN
.DS_Store vendored

Binary file not shown.

7
vitals
View file

@ -1,7 +1,6 @@
#!/bin/bash #!/bin/bash
adguard_test_domain='check.adguard.test' adguard_test_domain='check.adguard.test'
adguard_home_ip='100.64.64.15'
if [[ "$(uname)" == "Darwin" ]]; then if [[ "$(uname)" == "Darwin" ]]; then
# macOS # macOS
@ -35,7 +34,6 @@ else
blacklisted=false blacklisted=false
fi fi
# Check if Tailscale is installed and get IP # Check if Tailscale is installed and get IP
if command -v tailscale &> /dev/null; then if command -v tailscale &> /dev/null; then
has_tailscale=true has_tailscale=true
@ -79,10 +77,10 @@ fi
# Check AdGuard Home DNS # Check AdGuard Home DNS
resolved_ip=$(dig +short $adguard_test_domain) resolved_ip=$(dig +short $adguard_test_domain)
if [ "$resolved_ip" = "$adguard_home_ip" ]; then if [[ $resolved_ip =~ ^100\. ]]; then
adguard_connected=true adguard_connected=true
adguard_protocol="AdGuard Home" adguard_protocol="AdGuard Home"
adguard_client="$adguard_home_ip" adguard_client="$resolved_ip"
else else
adguard_connected=false adguard_connected=false
adguard_protocol="" adguard_protocol=""
@ -125,4 +123,3 @@ jq -n \
adguard_client: $adguard_client, adguard_client: $adguard_client,
uptime: $uptime uptime: $uptime
}' }'