Documentation ¶
Index ¶
- func DomainNameWithSubdomain(searchDomains []string, subdomain string) string
- func GetDomainName(searchDomains []string) string
- func GetLongestServiceDomainName(searchDomains []string) string
- func GetServiceDomainList(searchDomains []string) []string
- func ParseNameservers(content string) ([][]byte, error)
- func ParseSearchDomains(content string) ([]string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DomainNameWithSubdomain ¶
DomainNameWithSubdomain returns the DNS domain according subdomain. In case subdomain already exists in the domain, returns empty string, as nothing should be added. In case subdomain is empty, returns empty string, as nothing should be added. The motivation is that glibc prior to 2.26 had 6 domain / 256 bytes limit, Due to this limitation subdomain.namespace.svc.cluster.local DNS was not added by k8s to the pod /etc/resolv.conf. This function calculates the missing domain, which will be added by kubevirt. see https://github.com/kubernetes/kubernetes/issues/48019 for more details.
func GetDomainName ¶
GetDomainName returns the longest search domain entry, which is the most exact equivalent to a domain
func GetLongestServiceDomainName ¶ added in v0.49.1
GetLongestServiceDomainName returns the longest service search domain entry
func GetServiceDomainList ¶ added in v0.49.1
GetServiceDomainList returns a list of search domains which are a service entry
func ParseNameservers ¶
func ParseSearchDomains ¶
Types ¶
This section is empty.