Once enable, we shall see nginx available in Ingress Classes
Step 3: Deploy Ingress Nginx.
Run below command,
$ kubectl apply -f awx-nginx-ingress.yml
Above command will create below Ingress object
awx-nginx-ingress object created
To see more details about our HTTP/HTTPS network routing, we shall be able to describe the object by running the following command.
$ kubectl describe ingress-nginx
More details can be seen when we describe the object
As you can see on the above image, my specified subdomain tower.home-cloud01.lab was routed to the backend service - awx-nginx-service (the AWX service) on port 80.
Step 4: Modify hosts file
We will need to modify hosts file in our host server.
$ kubectl get ingress awx-nginx-ingress -n awx | grep -v NAME | awk -F' ' '{print $4 " " $3 }' | sudo tee -a /etc/hosts
Verify the host has been added into the /etc/hosts file
my /etc/hosts file
Step 5: Verify the connectivity.
So now we have the Ingress setup for our network routes. Let's test the connection.