In Kubernetes, you have to create so called services if you would like to connect to specific deployments
using specific IP addresses and there are different options available, you could create so called cluster
IP, and such a IP address will be created and assigned to specific deployment and you will be able
to connect to this specific deployment only inside of the cluster using this virtual IP address.
And Kubernetes will distribute load across different ports which are assigned to specific deployment.
But please note that such IP address will be just a single IP address for entire deployment.
And of course it is much more convenient to use such a IP address than specific IP addresses of the
ports as we just tried.
Also, there was an option to create external IP addresses to open deployment to outside world, and
it is possible to expose specific deployment to the IP address of the node or use a load balancer or
kept it inside of the Kubernetes cluster.
It is possible to have multiple nodes and ports could be distributed across different nodes.
Therefore, the most common solution is to have a load balancer IP address, which will be just single
for entire Kubernetes cluster for specific deployment.
And you will be able to connect to your deployment no matter where our ports are created using just
a single external IP address.
But such load balancer IP addresses are usually assigned by specific cloud provider like Amazon Web
Services or Google Cloud, and such assignments are managed by Cloud Controller Manager.
It is service which is running on the master node.