resolver

package
v0.0.0-...-173f4c4 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UpstreamFallback = "1.1.1.1:53"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DNS

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

func NewDNS

func NewDNS(conn net.PacketConn, handler DNSHandler, upstream string) (*DNS, error)

func (*DNS) ListenAndServe

func (d *DNS) ListenAndServe() error

func (*DNS) ServeDNS

func (d *DNS) ServeDNS(w dns.ResponseWriter, r *dns.Msg)

func (*DNS) Shutdown

func (d *DNS) Shutdown(ctx context.Context) error

type DNSHandler

type DNSHandler func(typ, host string) (string, bool)

type Ingress

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

func NewIngress

func NewIngress(kc *kubernetes.Clientset) (*Ingress, error)

func (*Ingress) HostExists

func (i *Ingress) HostExists(host string) bool

func (*Ingress) Start

func (i *Ingress) Start()

func (*Ingress) Stop

func (i *Ingress) Stop()

type Resolver

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

func New

func New(namespace string) (*Resolver, error)

func (*Resolver) Serve

func (r *Resolver) Serve() error

func (*Resolver) Shutdown

func (r *Resolver) Shutdown(ctx context.Context) error

type Server

type Server interface {
	ListenAndServe() error
	Shutdown(ctx context.Context) error
}

type Service

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

func NewService

func NewService(kc *kubernetes.Clientset) (*Service, error)

func (*Service) IP

func (s *Service) IP(host string) (string, bool)

func (*Service) Start

func (s *Service) Start()

func (*Service) Stop

func (s *Service) Stop()

Jump to

Keyboard shortcuts

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