Skip to main content

Nginx Tunning

Nginx GeoIP

https://mailfud.org/geoip-legacy/

Install Nginx Module

apt install nginx-module-geoip

The GeoIP dynamic modules for nginx have been installed.
To enable these modules, add the following to /etc/nginx/nginx.conf
and reload nginx:

    load_module modules/ngx_http_geoip_module.so;
    load_module modules/ngx_stream_geoip_module.so;
    
    http {
        geoip_country /usr/share/GeoIP/GeoIP.dat;
        geoip_city /usr/share/GeoIP/GeoIPCity.dat;
    }
    
    
    VHOST{
    add_header X-GeoIP "$geoip_country_code";
    }

NGINX Tuning For Best Performance

https://gist.github.com/denji/8359866