I created a kubernetes service that is exposed via type: nodePort
. I can access the service in my browser if I enter http://PublicDropletIp:31433.
Now I want to use a DigitalOcean Load Balancer to forward traffic from port 80
to the service. So I set a rule for the Load Balancer to forward http/80
to Droplet http/31433
.
Unforutnatly this doesn't work. If I enter the load balancer IP in the browser I get: 503 Service Unavailable
.
Does anyone know how I can expose the service so that the Load Balancer can forward traffic to it?
I had this same issue and ended up on this thread. If anyone else is looking, I resolved it by configuring the firewall on my server.
To answer the question above, the firewall should be configured to accept tcp
connections from the load balancer's ip on port 31433
.