Interview Q&A / Docker & Kubernetes

BeginnerQuick answer1 min readUpdated 3 Oct 2026

What is an Ingress in Kubernetes and how does it differ from a LoadBalancer Service?

SHORT ANSWER

An Ingress defines HTTP and HTTPS routing rules by host and path, handled by an Ingress controller. One load balancer can serve many services, while a LoadBalancer Service creates one external load balancer per Service.

Explain it simply

A LoadBalancer Service is a separate gate with its own security guard for each building. An Ingress is one main gate with a receptionist who reads the visitor's slip and directs them: 'accounts, go to block A; library, go to block B'.

The Ingress object is only a set of rules, such as shop.example.in/api goes to the api Service and shop.example.in/ goes to web. Nothing happens until an Ingress controller, such as ingress-nginx, Traefik or a cloud controller, is running; it reads the rules and does the routing. Benefits: one public IP for many services, TLS termination in one place, host and path routing, and lower cloud cost than many load balancers. Limitation: classic Ingress handles HTTP/HTTPS only. The newer Gateway API is its more expressive successor.

Example

yaml
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: shop
spec:
  ingressClassName: nginx
  rules:
    - host: shop.example.in
      http:
        paths:
          - path: /api
            pathType: Prefix
            backend:
              service: {name: api, port: {number: 80}}

What to say in the interview

"An Ingress holds HTTP/HTTPS routing rules by host and path, implemented by an Ingress controller. One entry point serves many Services, unlike a LoadBalancer Service which creates one load balancer per Service."

Common mistakes

  • Creating an Ingress without installing an Ingress controller.

#kubernetes#ingress#networking

Related questions

Practise more Docker & Kubernetes questions

Test your recall with short answers, then return to the detailed explanations when you need context.

Open Docker & Kubernetes quick answers →

Get new questions like this by email

One short email when something new and useful lands. No spam, unsubscribe in one tap.

By subscribing you agree to the Privacy Policy.