Providing DNS for Kubernetes services with bare metal load balancer

497 Views Asked by At

I'm trying to use external-dns with a bare metal load balancer. I tried using metallb as the kubernetes load balancer, but the IP address assigned in the A record is the internal IP address of the load balancer, rather than than the public IP address of the load balancer. According the to the external-dns docs, if status.loadBalancer is empty (which it will always be), external-dns would not work as expected even though I have set the external IP for the service.

1

There are 1 best solutions below

0
On

external-dns needs to become aware of the IP address of the loadbalancer. If the status.loadbalancer field is empty, one way how to make external-dns aware of the correct IP is to use the annotation external-dns.alpha.kubernetes.io/target: "<metalLB-vip>"