From 46457eab01b5795306bd0a468306aeca54ae8362 Mon Sep 17 00:00:00 2001 From: David Xia Date: Thu, 30 Jan 2025 15:11:06 -0500 Subject: [PATCH] docs: add an example of a Service-scoped Pod DNS record This example will help the reader understand. It's also more consistent to provide an example like the preceding Pod-scoped DNS record paragraphs. Update the other example to be consistent with the Pod DNS name's format. Signed-off-by: David Xia --- .../concepts/services-networking/dns-pod-service.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/content/en/docs/concepts/services-networking/dns-pod-service.md b/content/en/docs/concepts/services-networking/dns-pod-service.md index fd55849035..cfb1b66f4e 100644 --- a/content/en/docs/concepts/services-networking/dns-pod-service.md +++ b/content/en/docs/concepts/services-networking/dns-pod-service.md @@ -105,7 +105,7 @@ Kube-DNS versions, prior to the implementation of the had the following DNS resolution: ``` -pod-ipv4-address.my-namespace.pod.cluster-domain.example +..pod. ``` For example, if a Pod in the `default` namespace has the IP address 172.17.0.3, @@ -121,6 +121,14 @@ Some cluster DNS mechanisms, like [CoreDNS](https://coredns.io/), also provide ` ...svc. ``` +For example, if a Pod in the `cafe` namespace has the IP address 172.17.0.3, +is an endpoint of a Service named `barista`, and the domain name for your cluster is +`cluster.local`, then the Pod would have this service-scoped DNS `A` record. + +``` +172-17-0-3.barista.cafe.svc.cluster.local +``` + ### Pod's hostname and subdomain fields Currently when a Pod is created, its hostname (as observed from within the Pod)