Merhaba,

Nginx geoip2 modülünü kurabilirsiniz. https://github.com/leev/ngx_http_geoip2_module

ardından basit bir conf ile engelleyebilirsiniz. Örnek ;

* geoip2 /mmdbyolu/GeoLite2-Country.mmdb {    $geoip2_data_country_code country iso_code;  }  map $geoip2_data_country_code $allowed_country {    default yes;    CN no;* }
  server {    listen       80;    server_name  localhost;    if ($allowed_country = no) {      return 403;    }* * }
gibi conf dosyaları üzerinde ayar yaparak ülkeyi engelleyebilirsiniz. Ülke iso kodlarını https://www.iban.com/country-codes buradan alabilirsiniz.