dns

package
v0.3.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 28, 2022 License: GPL-3.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DropHosts

func DropHosts()

DropHosts remove hosts domain record added by kt

func DumpHosts

func DumpHosts(hostsMap map[string]string, namespaceToDrop string) error

DumpHosts dump service domain to hosts file

func GetLocalDomains

func GetLocalDomains() string

GetLocalDomains get domain search postfixes

func GetNameServer

func GetNameServer() string

GetNameServer get primary dns server

func HandleExtraDomainMapping added in v0.3.6

func HandleExtraDomainMapping(extraDomains map[string]string, localDnsPort int)

HandleExtraDomainMapping handle extra domain change

func RestoreNameServer added in v0.3.6

func RestoreNameServer()

RestoreNameServer remove the nameservers added by ktctl

func SetNameServer added in v0.3.6

func SetNameServer(dnsServer string) error

SetNameServer set dns server records

func SetupLocalDns

func SetupLocalDns(remoteDnsPort, localDnsPort int, dnsOrder []string) error

Types

type DnsServer

type DnsServer struct {
	// contains filtered or unexported fields
}

func (*DnsServer) ServeDNS

func (s *DnsServer) ServeDNS(w dns.ResponseWriter, req *dns.Msg)

ServeDNS query DNS record

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL