Interview Prep/Kubernetes/Services, Ingress and DNS

You want to expose three HTTP services under one hostname with different paths. How?

IntermediateScenarioServices, Ingress and DNS
Answer

Situation read → /api, /web and /admin must share app.example.com and one load balancer.

What I'd do →

  1. Install an ingress controller such as ingress-nginx or the AWS Load Balancer Controller
  2. Create an Ingress with rules.host and three paths with pathType: Prefix
  3. Add TLS using a cert-manager Certificate and tls.secretName
  4. Use annotations only for controller-specific behaviour
  5. Test with curl -H 'Host: app.example.com' http://<lb>/api

Why → One L7 entry point routes by host and path, saving LBs and centralising TLS.

Interview tip → Mention Gateway API (GA) as the successor with HTTPRoute and role separation.

All Kubernetes questions Roadmap: Kubernetes networking, storage & scaling

More on Services, Ingress and DNS