updated to php 7.4.2 but geoip is broken - to fix

This commit is contained in:
ric
2020-02-03 22:08:43 +00:00
parent 218147f77a
commit 5f7fcc2d5f
6 changed files with 84 additions and 77 deletions

View File

@@ -33,37 +33,38 @@ http {
server_tokens off;
#gzip on;
geoip2 /etc/nginx/GeoLite2-Country.mmdb {
auto_reload 1h;
$geoip2_metadata_country_build metadata build_epoch;
# populate the country
$geoip2_data_country_code source=$remote_addr country iso_code;
$geoip2_data_country_name source=$remote_addr country names en;
# populate the continent
$geoip2_data_continent_code source=$remote_addr continent code;
$geoip2_data_continent_name source=$remote_addr continent names en;
}
geoip2 /etc/nginx/GeoLite2-City.mmdb {
auto_reload 1h;
# City name itself
$geoip2_data_city_name source=$remote_addr city names en;
# Postal code will be an approximation, probably the first one in the list that covers an area
$geoip2_data_postal_code source=$remote_addr postal code;
# State in code and long form
$geoip2_data_state_code source=$remote_addr subdivisions 0 iso_code;
$geoip2_data_state_name source=$remote_addr subdivisions 0 names en;
# Lat and Lng
$geoip2_data_latitude source=$remote_addr location latitude;
$geoip2_data_longitude source=$remote_addr location longitude;
}
# Disabled due to license
# geoip2 /etc/nginx/GeoLite2-Country.mmdb {
# auto_reload 1h;
#
# $geoip2_metadata_country_build metadata build_epoch;
#
# # populate the country
# $geoip2_data_country_code source=$remote_addr country iso_code;
# $geoip2_data_country_name source=$remote_addr country names en;
#
# # populate the continent
# $geoip2_data_continent_code source=$remote_addr continent code;
# $geoip2_data_continent_name source=$remote_addr continent names en;
# }
#
# geoip2 /etc/nginx/GeoLite2-City.mmdb {
# auto_reload 1h;
#
# # City name itself
# $geoip2_data_city_name source=$remote_addr city names en;
#
# # Postal code will be an approximation, probably the first one in the list that covers an area
# $geoip2_data_postal_code source=$remote_addr postal code;
#
# # State in code and long form
# $geoip2_data_state_code source=$remote_addr subdivisions 0 iso_code;
# $geoip2_data_state_name source=$remote_addr subdivisions 0 names en;
#
# # Lat and Lng
# $geoip2_data_latitude source=$remote_addr location latitude;
# $geoip2_data_longitude source=$remote_addr location longitude;
# }
include /etc/nginx/sites-enabled/*;
}