Configure Host-Based and Path-Based Routing
Explore how to deploy multiple applications with ClusterIP services and configure a Kubernetes Ingress object to manage host-based and path-based routing. Understand how to route traffic efficiently using a single load balancer and adjust DNS to resolve hostnames to services within your cluster.
We'll cover the following...
In the upcoming lessons, we'll deploy two apps and a single Ingress object. The Ingress will route traffic to both apps via a single load balancer. This can be a cloud-based load balancer or localhost on a local cluster.
We’ll complete all the following steps:
Deploy an app called
shieldand front it with aClusterIPService (backend) calledsvc-shield.Deploy an app called
hydraand front it with aClusterIPService (backend) calledsvc-hydra.Deploy an Ingress object that creates a single load balancer and routing rules for the following hostnames and paths:
Host-based:
shield.mcu.com>>svc-shieldHost-based:
hydra.mcu.com>>svc-hydraPath-based:
mcu.com/shield>>svc-shieldPath-based: ...