proxy

package
v0.0.0-...-9bd6815 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2024 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	ListenAddr                  string   `mapstructure:"listen_addr" validate:"required"`
	Upstreams                   []string `mapstructure:"upstreams" validate:"required"`
	UpstreamDialTimeoutSeconds  int      `mapstructure:"upstream_dial_timeout_seconds"`
	UpstreamReadTimeoutSeconds  int      `mapstructure:"upstream_read_timeout_seconds"`
	UpstreamWriteTimeoutSeconds int      `mapstructure:"upstream_write_timeout_seconds"`
	UpstreamTotalTimeoutSeconds int      `mapstructure:"upstream_total_timeout_seconds"`
	ProxyZones                  []string `mapstructure:"proxy_zones"`
}

type Server

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

func New

func New(logger *zap.Logger, resolver resolvers.Resolver, config *Config) *Server

func (*Server) ListenAndServeContext

func (s *Server) ListenAndServeContext(ctx context.Context) error

Jump to

Keyboard shortcuts

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