From the course: Certified Kubernetes Application Developer (CKAD) Cert Prep

Unlock this course with a free trial

Join today to access over 24,700 courses taught by industry experts.

Using ingress

Using ingress

- Alright, now that we have the ingress controller running, let's create some ingress. I prepared the demo. Here are the steps in the demo. Let me run it for you. Now actually, we already created the deployment nginx-svc, right? So if I use kubectl, I'll get all --selector app is nginx-svc. We should see that. As you can see, I already have a service nginx-svc, so we're cool. We don't have to do anything. And we can start talking about ingress immediately. So kubectl create ing, which is short for ingress, -h | less. That's my favorite approach if I need to do ingress. Now, in CKAD ingress is pretty simple, so no need to work with TLS certificates or anything. And all you need to know is right here in this example line. I'm skipping the part TLS is my cert and I want to analyze the rest, which is kubectl create ingress simple. So the name of the ingress is simple and then the important part is the rule. Now, what do we get in the rule? Well, you get a link that ingress is going to…

Contents