Skip to content

Commit

Permalink
add var for location of Geoblock
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Hansson <[email protected]>
  • Loading branch information
enoch85 authored Sep 22, 2024
1 parent 6a111c7 commit 03c9927
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -425,12 +425,14 @@ download_geoip_mmdb() {
else
docker rm -f maxmind
rm -f /tmp/dockerenv
print_text_in_color "$ICyan" "Rate limit for Maxmind GeoDatabase reached! We're now trying to get the Country Database from https://ipinfo.io instead."
if ! curl -sfL https://ipinfo.io/data/free/country.mmdb?token="$x8v8GyVQg2UejdPh" -o "$GEOBLOCK_DIR"/GeoLite2-Country.mmdb
then
msg_box "Sorry, we couldn't get the needed IP geolocation database from any source, please try again in 24 hours."
return 1
fi
msg_box "Update limit for Maxmind GeoDatabase reached! Please try again tomorrow."
return 1
#print_text_in_color "$ICyan" "Rate limit for Maxmind GeoDatabase reached! We're now trying to get the Country Database from https://ipinfo.io instead."
#if ! curl -sfL https://ipinfo.io/data/free/country.mmdb?token="$x8v8GyVQg2UejdPh" -o "$GEOBLOCK_DIR"/GeoLite2-Country.mmdb
#then
# msg_box "Sorry, we couldn't get the needed IP geolocation database from any source, please try again in 24 hours."
# return 1
#fi
fi
unset x8v8GyVQg2UejdPh
}
Expand Down

0 comments on commit 03c9927

Please sign in to comment.