Configuring cluster networking

Now that we have a cluster deployed with three nodes and a deployment with varying number of pods, let's look at how to expose these pods so we can access our application. Kubernetes services are exposed by using a load balancer. Load balancing allows your cluster services to be available on a single IP address. In Kubernetes, you create internal load balancers, which make it easier for you to expose your services between GCP applications, if needed.

For our exercise here, exposing the deployed pods to the internet is easy. If you noticed, we had deployed the nginx images as our workloads. Let's look at exposing this to the internet so we can access our pods:

  1. Open up your workload and click on Expose:

Get Google Cloud Platform Administration now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.