This tutorial assumes you have magento installed
Install geoip module and database:
sudo apt-get install libgeoip1 libnginx-mod-http-geoip geoip-database-extra -y
Update GeoIP databases:
cd /usr/share/GeoIP
mv GeoIP.dat GeoIP.dat.bak
curl -O https://dl.miyuru.lk/geoip/maxmind/country/maxmin...
Read more