EKS Ingress with Single ALB, multiple namespaces, and External DNS
System Design practice on Codemia
Work through 120+ system design problems with detailed solutions, from rate limiters to multi-region storage.
Introduction to EKS Ingress with Single ALB
Amazon Elastic Kubernetes Service (EKS) is a managed service that allows you to run Kubernetes on AWS without needing to set up your own Kubernetes control-plane or nodes. In Kubernetes, Ingress is an API object that manages external access to services, typically HTTP. EKS integrates with AWS’s services like Elastic Load Balancer (ELB) to streamline delivering your application to the outside world.
In scenarios where multiple namespaces need to share a single AWS Elastic Load Balancer Application Load Balancer (ALB), it’s key to understand the configuration of the Ingress resource. Additionally, the integration with External DNS helps automate the management of DNS records in Route 53.
ALB Ingress with Multiple Namespaces
Technical Explanation
To use a single ALB with multiple namespaces, you will configure Ingress resources in each namespace targeting the same ALB. The Ingress Controller listens for changes in these resources and configures the ALB accordingly.
- Install ALB Ingress Controller: The ALB Ingress Controller, now part of the AWS Load Balancer Controller, is essential for integrating Kubernetes Ingress resources with AWS's ALB.
- Security: Ensure that security groups and Network ACLs are properly set to handle communication from the ALB to EKS worker nodes.
- Routing: Use path-based routing or host-based routing to properly segment traffic to services.
- Annotations: Use Kubernetes annotations to specify configurations such as SSL certificate management, redirect rules, etc.
- host: example-a.app.com
- backend:
- port: 80
- Domain Management: Carefully consider how domain names are structured across applications.
- Observability: Ensure monitoring solutions are in place for the external DNS components and the health of DNS itself.
- IAM and Permissions: Managing AWS IAM roles for Kubernetes service accounts can be complex. Automating IAM role assignments can minimize configuration drift.
- Scalability: As traffic grows, ensure the ALB has scalability parameters properly defined, like adequate target protections and limits on connections.
- Conflicts in Rules: Ensure configuration guidelines are adhered to, avoiding rule conflicts in Ingress definitions across namespaces.
Related reading
- EKS Kubernetes outbound traffic
- eksctl create cluster stuck waiting for CloudFormation stack
- Elastic Search Adding nodes to cluster on the fly
- Elasticsearch 7.2.0 master not discovered or elected yet, an election requires at least X nodes
- ElasticSearch Java API asynchronous writing
- Empty ADDRESS kubernetes ingress
- Elasticsearch fails to start on AWS kubernetes cluster
- Elasticsearch helm chart gives AccessDenied exception

System Design Fundamentals
Build a strong foundation in designing scalable, reliable distributed systems.
View the courseTrack what you have practised
A free account saves your progress, solutions and study plan across every problem on Codemia.
System Design practice on Codemia
Work through 120+ system design problems with detailed solutions, from rate limiters to multi-region storage.