Skip to content

Commit

Permalink
Update pgscan.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
MrDoobPG authored and MrDoobPG committed Nov 29, 2019
1 parent ca0c7ee commit d6721d7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion menu/pgscan/pgscan.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ tokenstatus() {
if [[ ! -f "/opt/plex_autoscan/config/config.json" ]]; then
pstatus="❌ DEPLOYED BUT PAS CONFIG MISSING";
else
PGSELFTEST=$(curl -LI "http://localhost:32400/system?X-Plex-Token=$(cat /opt/plex_autoscan/config/config.json | jq .PLEX_TOKEN | sed 's/"//g')" -o /dev/null -w '%{http_code}\n' -s)
PGSELFTEST=$(curl -LI "http://$(hostname -I | awk '{print $1}'):32400/system?X-Plex-Token=$(cat /opt/plex_autoscan/config/config.json | jq .PLEX_TOKEN | sed 's/"//g')" -o /dev/null -w '%{http_code}\n' -s)
if [[ $PGSELFTEST -ge 200 && $PGSELFTEST -le 299 ]]; then pstatus="✅ DEPLOYED"
else pstatus="❌ DEPLOYED BUT PAS TOKEN FAILED"; fi
fi
Expand Down

0 comments on commit d6721d7

Please sign in to comment.