Comment

Comment by hijinks

Generally you have to figure out a way to do the load balancing.

Once way is like haproxy in front that has each of the k8 nodes behind it.

How I did it in AWS since I didn't want k8 to create ELBs is

ELB->nginx (on the node outside of k8) -> k8 service nodeport

A nodeport is a type of service that opens the same port on all the k8 nodes to send traffic from the outside to inside the cluster. Even if a node doesn't run the container it can forward traffic to a node that does.

There are also now ingress controllers you can look at that do a lot of the work for you to reload what I did with nginx as soon as you create a service in k8.

parent hijinks 10 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton