Skip to content

Commit

Permalink
Fix segment wan_ip (#430)
Browse files Browse the repository at this point in the history
* Fix protocol error for wan-ip url, change from `http` to `https`
  • Loading branch information
matrixzj authored May 31, 2024
1 parent 29143d8 commit 6aea97f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion segments/wan_ip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ run_segment() {
fi

if [ -z "$wan_ip" ]; then
if wan_ip=$(curl --max-time 2 -s http://whatismyip.akamai.com/); then
if wan_ip=$(curl --max-time 2 -s https://whatismyip.akamai.com/); then
echo "${wan_ip}" >"$tmp_file"
elif [ -f "${tmp_file}" ]; then
wan_ip=$(cat "$tmp_file")
Expand Down

0 comments on commit 6aea97f

Please sign in to comment.