How to assign an EIP to an AWS NLB in Kubernetes

Craig Newton
Jun 7, 2019

--

Out of the box Kubernetes has no support for assigning an EIP to an AWS Network Load Balancer. There is currently a pull request for this feature listed here: https://github.com/kubernetes/kubernetes/issues/63959#issuecomment-484203661

This feature request has unfortunately not been approved yet.

Not to worry though I have put together a simple application you can run as a CronJob on your current Kubernetes cluster that will clone the targets from your Kubernetes Service LoadBalancer to an AWS Network Load Balancer that you create and have an EIP assigned to.

Docker hub repository: https://hub.docker.com/r/newtondev/k8s-aws-nlb-target-cloner

Source code repository: https://github.com/newtondev/k8s-aws-nlb-target-cloner

More Resources

Want to learn more about Kubernetes. Please check out this great book that I helped review:

The Kubernetes Workshop
The Kubernetes Workshop

https://www.packtpub.com/product/the-kubernetes-workshop/9781838820756

--

--