From c8ce95ecda310bd5fd3aefea28c4e06811c54dcb Mon Sep 17 00:00:00 2001 From: MrDoobPG <46342172+MrDoobPG@users.noreply.github.com> Date: Mon, 9 Dec 2019 00:19:49 +0100 Subject: [PATCH] Update plexpatrol.sh --- menu/plexpatrol/plexpatrol.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/menu/plexpatrol/plexpatrol.sh b/menu/plexpatrol/plexpatrol.sh index 51153d7c..688f6399 100644 --- a/menu/plexpatrol/plexpatrol.sh +++ b/menu/plexpatrol/plexpatrol.sh @@ -62,7 +62,7 @@ token() { if [[ ! -f "/opt/appdata/plexpatrol/settings.ini" ]]; then pstatus="❌ DEPLOYED BUT PAPTROL CONFIG MISSING"; else - PGSELFTEST=$(curl -LI "http://localhost:32400/system?X-Plex-Token=$(cat /opt/appdata/plexpatrol/settings.ini | grep "SERVER_TOKEN" | awk '{print $3}')" -o /dev/null -w '%{http_code}\n' -s) + PGSELFTEST=$(curl -LI "http://$(hostname -I | awk '{print $1}'):32400/system?X-Plex-Token=$(cat /opt/appdata/plexpatrol/settings.ini | grep "SERVER_TOKEN" | awk '{print $3}')" -o /dev/null -w '%{http_code}\n' -s) if [[ $PGSELFTEST -ge 200 && $PGSELFTEST -le 299 ]]; then pstatus="✅ DEPLOYED" else pstatus="❌ DEPLOYED BUT PATROL TOKEN FAILED"; fi fi