ingress-nginx — Kubernetes NGINX Ingress Controller
ingress-nginx is the community Kubernetes ingress controller built on NGINX, turning Ingress and Gateway API resources into production-ready HTTP/S and TCP load-balancer configuration.
What it is
ingress-nginx is the community-maintained Kubernetes ingress controller built on NGINX. It translates Kubernetes Ingress and Gateway API resources into NGINX configuration, providing HTTP/S load balancing, TLS termination, path-based routing, and rate limiting for cluster services. It is the most widely deployed ingress controller in the Kubernetes ecosystem.
The controller targets platform engineers and DevOps teams running Kubernetes clusters who need to expose services to external traffic. It works on every major cloud provider and on-premises Kubernetes distributions.
How it saves time or tokens
ingress-nginx eliminates manual NGINX configuration management. Instead of writing and reloading NGINX configs, you declare routing rules as Kubernetes Ingress resources, and the controller generates and applies the configuration automatically. Annotations provide fine-grained control over rate limiting, CORS, SSL redirects, and upstream behavior without touching NGINX config files directly.
How to use
- Install with the official Helm chart:
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx
helm upgrade --install ingress-nginx ingress-nginx/ingress-nginx \
-n ingress-nginx --create-namespace
- Create an Ingress resource for your service:
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: my-app
annotations:
nginx.ingress.kubernetes.io/ssl-redirect: 'true'
spec:
ingressClassName: nginx
rules:
- host: app.example.com
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: my-app-svc
port:
number: 80
- Apply the resource and verify the external IP:
kubectl get ingress my-app.
Example
Rate limiting and CORS configuration via annotations:
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: api-ingress
annotations:
nginx.ingress.kubernetes.io/rate-limit: '100'
nginx.ingress.kubernetes.io/rate-limit-window: '1m'
nginx.ingress.kubernetes.io/enable-cors: 'true'
nginx.ingress.kubernetes.io/cors-allow-origin: 'https://frontend.example.com'
spec:
ingressClassName: nginx
rules:
- host: api.example.com
http:
paths:
- path: /v1
pathType: Prefix
backend:
service:
name: api-svc
port:
number: 8080
Related on TokRepo
- AI Tools for DevOps — DevOps tools for Kubernetes deployment and cluster management
- AI Tools for Monitoring — Monitoring tools for tracking ingress controller metrics
Common pitfalls
- The community ingress-nginx and the NGINX Inc ingress controller are different projects. Ensure you install the community version from
kubernetes.github.io/ingress-nginx. - Annotation typos fail silently. A misspelled annotation key is ignored, and the default behavior applies without warning.
- TLS certificates must be stored as Kubernetes secrets and referenced in the Ingress spec. Missing or expired certificates cause 502 errors, not helpful error messages.
- Always check the official documentation for the latest version-specific changes and migration guides before upgrading in production environments.
- For team deployments, establish clear guidelines on configuration and usage patterns to ensure consistency across developers.
Frequently Asked Questions
ingress-nginx is the community-maintained controller from the Kubernetes project. NGINX Ingress Controller is a separate product by NGINX Inc (F5). They use different annotation prefixes, different Helm charts, and have different feature sets.
Yes. ingress-nginx handles TLS termination by referencing Kubernetes TLS secrets in the Ingress spec. It also integrates with cert-manager for automatic certificate provisioning and renewal via Let's Encrypt.
Add the annotation nginx.ingress.kubernetes.io/rate-limit with the desired requests-per-minute value to your Ingress resource. The rate-limit-window annotation controls the time window for the limit.
Yes. ingress-nginx supports WebSocket connections by default. For long-lived WebSocket connections, increase the proxy-read-timeout and proxy-send-timeout annotations to prevent premature connection closure.
Yes. Recent versions of ingress-nginx support the Kubernetes Gateway API in addition to traditional Ingress resources. Gateway API provides more expressive routing capabilities and is the future direction for Kubernetes traffic management.
Citations (3)
- ingress-nginx GitHub— ingress-nginx is the community Kubernetes NGINX ingress controller
- Kubernetes Documentation— Kubernetes Ingress API specification
- ingress-nginx Docs— Helm chart installation for ingress-nginx
Related on TokRepo
Discussion
Related Assets
Conda — Cross-Platform Package and Environment Manager
Install, update, and manage packages and isolated environments for Python, R, C/C++, and hundreds of other languages from a single tool.
Sphinx — Python Documentation Generator
Generate professional documentation from reStructuredText and Markdown with cross-references, API autodoc, and multiple output formats.
Neutralinojs — Lightweight Cross-Platform Desktop Apps
Build desktop applications with HTML, CSS, and JavaScript using a tiny native runtime instead of bundling Chromium.