dev-resources.site
for different kinds of informations.
nginx-mod-http-geoip
Published at
1/15/2025
Categories
nginx
infrastructure
Author
medrix
Main Article
Author
6 person written this
medrix
open
nginx-mod-http-geoip
nginx-mod-http-geoip
is an nginx module that allows you to determine the geographical location of an IP address. The geo of country is presented by Alpha-2 code.
You can find ISO ISO’s full, searchable list of all country codes to find your code.
map $geoip_country_code $allowed_country {
default no;
RU yes; # <ISO 3166-1 alpha-2> <yes/no>
}
server {
...
if ($allowed_country = no) {
return 403;
}
...
}
Enjoy you practice 🌟
nginx Article's
30 articles in total
nginx-mod-http-geoip
currently reading
How to run a Nginx-web server
read article
ngx whitelist/blacklist module
read article
Nginx Simplified: Technical Insights with Real-World Analogies
read article
Nginx Configuration Tips for Secure Communication: Enabling mTLS and checking client fingerprint
read article
Building a Scalable Reverse Proxy Server like Nginx with Node.js and TypeScript
read article
Deploy NestJS and NextJS application in same server using pm2 and Nginx
read article
Setting Up an NGINX Reverse Proxy with a Node.js Cluster Using Docker
read article
การทำ HTTPS ด้วย Certbot และ Nginx บน Ubuntu Server
read article
How to configure Free SSL Certificate on Nginx using Certbot
read article
Docker Hands-on: Learn Docker Volume and Bind Mounts with Sample Projects using NGINX
read article
自建的git远程仓库,在push时413 Request Entity Too Large
read article
Optimize SvelteKit performance with brotli compression
read article
I’m running a Spring Boot application inside a Docker container on my VM. The application works fine over HTTP, and I can access all endpoints via http://127.0.0.1:8080. I’ve set up NGINX as a reverse proxy to serve HTTPS requests. No errors for http reqs.
read article
Deploying a MERN App on Azure: The Smart Way
read article
My First Full-Stack Deployment with Docker and NGINX as Load Balancer
read article
Streamlined Release Process for a Web Application: Trunk-Based Development with Feature Flags
read article
How to Install NGINX on Ubuntu 22.04
read article
Secure Nginx with Let's Encrypt on Ubuntu
read article
Kubernetes Ingress Controllers and NGINX Ingress: A Complete Guide
read article
What is HTTP 499 Status Code and How to Fix it?
read article
Docker Compose Demo: Running Multiple Services with Two Domains on Localhost
read article
Building a Production Stack: Docker, Meilisearch, NGINX & NestJS
read article
Step-by-Step Guide: Assigning a Namecheap Domain to DigitalOcean Hosting with Nginx
read article
Streamlining React CI/CD Pipelines with GitHub Actions
read article
Connecting to an EC2 Instance with Ubuntu and Installing NGINX on AWS
read article
Installing Nginx Web Server on Linux: A Step-by-Step Guide
read article
Hosting multiple Websites on a single Nginx Server
read article
Unleashing the Power of NGINX as an API Gateway
read article
Installing Wordpress with Nginx in Ubuntu
read article
Featured ones: