Let us now look at another type of service known as the load balancer type.
So we have seen the node port service that helps us make an external facing application available on
a port on the worker notice.
So let's turn our focus to the front end applications, which are the voting app and the result app.
Now, we know that these pods are hosted on the worker nodes in a cluster.
So let's say we have a four node cluster.
And to make the applications accessible to external users, we create these services of type node port.
Now the services with type node port help in receiving traffic on the ports, on the notes and routing
the traffic to the respective parts.
But what you are l would you give your end users to access the applications and you could access any
of these two applications using IP of any of the nodes and the high port.
The services exposed on, so that would be for IP and port combinations for the voting app and for IP
and port combination for the result app.
So not bad, even if your ports are only hosted on two of the nodes.
There will still be accessible on the eyepiece of all the notes in the cluster say the parts for the
voting app are only deployed on the nodes with IP 70 and 71.
There would still be accessible on the ports of all the nodes in the cluster.
So that's how our service is configured.
So you would share these.
You are El's to your users to access the application.
But that's not what the end users want.
They need a single you URL like example, voting app, dot com or the example a result app dot com to
access the application.
So how do you achieve that?
Now one way to achieve this is to create a new VM for a load balancer purpose and install and configure
a suitable load balancer on it like a proxy or engine X, etc. then configure the load balancer to route
traffic to the underlying notes.
Now, setting all of that external load balancing and then maintaining and managing, that can be a
tedious task.
However, if we were on a supported cloud platform like Google Cloud or NWS or Azure, I could leverage
the native load balancer off that cloud platform.
Cooper Netas has support for integrating with the native load balancers of certain cloud providers and
configuring and configuring that for us.
So all you need to do is set the service type for the friend and services to load balancer instead of
node port.
Now remember that this only works with support cloud platforms.
So GCP, it appears and and as your are definitely supported.
So if you set the type of service to load balancer.
In an unsupportive environment like a virtual box or, you know, any other environment, then it would
have the same effect as setting a two note port where, you know, the services are exposed on a high
end port on the notes there.
It just won't do any kind of external load balancer configuration.
Right.
So later on, when we walked through the demos of deploying our application on cloud platforms, we
will see this in action.
Right.
So that's it for now.
I will see you in the next lecture.