headless Service
A Service with no cluster IP whose DNS name returns the individual pod addresses, giving each pod a stable name of its own.
In more detail
StatefulSets use one so that each replica can be reached as web-0.web, web-1.web and so on. There is no load balancing through kube-proxy; clients pick a pod themselves. It is declared by setting clusterIP to None.
Related terms
- StatefulSet — The Kubernetes object for replicated applications where each pod needs a stable name and its own storage, such as databases.
- CoreDNS — The DNS server that runs inside a Kubernetes cluster and resolves Service and pod names.
- Kubernetes Service — The Kubernetes object that gives a changing set of pods one stable name and address, and spreads traffic across the ready ones.
Related guides
Taught in
- Services And Empty Endpoints — Certified Kubernetes Application Developer (CKAD) Exam Prep
- StatefulSets, Stable Identity And Data Recovery — Kubernetes: Production-Grade Container Orchestration