# DNS A record for container

**URL:** <https://forums.suse.com/t/dns-a-record-for-container/15759>\
**Category:** SUSE Rancher Prime\
**Created:** [November 7, 2019, 11:19am UTC](https://forums.suse.com/t/dns-a-record-for-container/15759 "2019-11-07T11:19:55Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Michal](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/michal/32/3206_2.png) [@Michal](https://forums.suse.com/u/Michal)\
**Post date:** [November 7, 2019, 11:19am UTC](https://forums.suse.com/t/dns-a-record-for-container/15759/1 "2019-11-07T11:19:55Z")

</div>

By default when enabled, pods are assigned a DNS A record in the form of `pod-ip-address.my-namespace.pod.cluster.local` .

For example, a pod with IP `1.2.3.4` in the namespace `default` with a DNS name of `cluster.local` would have an entry: `1-2-3-4.default.pod.cluster.local` .

But the hostname is the Pod’s `metadata.name` value.  
Is there a way to set the DNS A record to be the same metadata.name ?

Thanks

---

<div class="post-metadata">

**Author:** ![superseb](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/superseb/32/2424_2.png) [@superseb](https://forums.suse.com/u/superseb)\
**Post date:** [November 11, 2019, 3:43pm UTC](https://forums.suse.com/t/dns-a-record-for-container/15759/2 "2019-11-11T15:43:55Z")

</div>

Pretty sure this is covered in [https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-hostname-and-subdomain-fields](https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-hostname-and-subdomain-fields), could you give some more info on your use-case so we can think of a solution versus one implementation?
