Skip to content

Commit

Permalink
update log messages
Browse files Browse the repository at this point in the history
  • Loading branch information
mrhotio committed Feb 3, 2024
1 parent 86b31de commit c781dd3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions root/app/forwarded_port_update_app
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@ if grep -q 'WebUI\\HTTPS\\Enabled=true' "${CONFIG_DIR}/config/qBittorrent.conf";
fi
if grep -q 'WebUI\\LocalHostAuth=false' "${CONFIG_DIR}/config/qBittorrent.conf"; then
if ! curl -fsSL --retry 5 --retry-max-time 60 --insecure -X POST -d "json={\"web_ui_upnp\":false,\"upnp\":false,\"random_port\":false,\"listen_port\":${port}}" "${webui_https}://localhost:${WEBUI_PORTS%%/*}/api/v2/app/setPreferences"; then
echo "[ERROR] [$(date '+%Y-%m-%d %H:%M:%S')] Unable to set forwarded port in qBittorrent, something is wrong!"
echo "[ERROR] [$(date '+%Y-%m-%d %H:%M:%S')] [QBITTORRENT] Unable to set forwarded port, something is wrong!"
rm -rf "${CONFIG_DIR}/wireguard/forwarded_port"
else
echo "[INFO] [$(date '+%Y-%m-%d %H:%M:%S')] Updated forwarded port in qBittorrent."
echo "[INFO] [$(date '+%Y-%m-%d %H:%M:%S')] [QBITTORRENT] Updated forwarded port."
fi
else
echo "[WARNING] [$(date '+%Y-%m-%d %H:%M:%S')] Unable to set forwarded port in qBittorrent, \"LocalHostAuth\" is enabled!"
echo "[WARNING] [$(date '+%Y-%m-%d %H:%M:%S')] [QBITTORRENT] Unable to set forwarded port, \"LocalHostAuth\" is enabled!"
rm -rf "${CONFIG_DIR}/wireguard/forwarded_port"
fi

0 comments on commit c781dd3

Please sign in to comment.