Is possible to have same k8s service for multiple pods?

0 votes
I have 9 pods running with 9 diff apps. Is possible to have same k8s service for multiple pods such that I can access them by different ports, but the same IP of service?
Jul 20, 2018 in Kubernetes by Hannah
• 15,440 points
42 views

1 answer to this question.

0 votes
Reserve a static IP and then assign the same IP to multiple services ( Different service.yaml files ) and change the ports for the backend. Like one Load Balancer (service) with a static IP is pointing to a backend service and the same Load balancer with the same IP ( different service file ) is pointing to other service on different port.

This worked fine for me
answered Jul 20, 2018 by Kalgi
• 41,660 points

Related Questions In Kubernetes

0 votes
1 answer
0 votes
1 answer

How do I update all my pods if the image is changed but the tag is the same?

Make sure your imagePullPolicy is set to ...READ MORE

answered Jul 12 in Kubernetes by Sirajul
• 30,540 points
47 views
0 votes
1 answer
0 votes
3 answers

Error while joining cluster with node

Hi Kalgi after following above steps it ...READ MORE

answered Jan 17 in Others by anonymous
2,610 views
+3 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Is it possible to access GCP resources using api without a user interaction.?

yes that's totally possible. You'd have to create ...READ MORE

answered Sep 19, 2018 in Kubernetes by Kalgi
• 41,660 points
41 views