Install libnginx-mod-http-geoip by entering the following commands in the terminal:
sudo apt update sudo apt install libnginx-mod-http-geoip
Description:
GeoIP HTTP module for Nginx
The ngx_http_geoip module creates variables with values depending on the client IP address, using the precompiled MaxMind databases. . Those variables include country, region, city, latitude, longitude, postal code, etc.
Homepage: http://nginx.net
Version: 1.14.0-0ubuntu1
Section: httpd