Reputation: 7468
In Kubernetes configuration, for external service component we use:
type: LoadBalancer
If we have k8s cluster running inside a cloud provider like AWS, which provides it own loadbalancer, how does all this work then? Do we need to configure so that one of these loadbalancers is not active?
Upvotes: 1
Views: 406
Reputation: 1045
AWS now takes over the open source project: https://kubernetes-sigs.github.io/aws-load-balancer-controller
It works with EKS(easiest) clusters as well as non-EKS clusters(need to install aws vpc cni etc to make IP
target mode work, which is required if you have a peered VPC environment.)
This is the official/native solution of managing AWS LB(aka ELBv2) resources(App ELB, Network ELB) using K8s. Kubernetes in-tree controller always reconciles Service
object with type: LoadBalancer
Once configured correctly, AWS LB controller will manage the following 2 types of LBs:
Ingress
object. It operates on L7 and provides features related to HTTPService
object with correct annotations. It operates on L4 and provides less features but claimed MUCH higher throughput.To my knowledge, this works best when used with external-dns
together -- it automatically updates your Route53 record with your LB A records thus makes the whole service discovery solution k8s-y.
Also in general, should prevent usage of classic ELB, as it's marked as deprecated by AWS.
Upvotes: 1