Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Backend ¶
type Backend struct { Addr string `yaml:"addr" json:"addr"` ConnectTimeout int `yaml:"connect_timeout" json:"connectTimeout"` }
Backend struct
type Binding ¶
type Binding struct { BindAddr string `yaml:"bind_addr" json:"bindAddr"` Watch bool `yaml:"watch" json:"watch"` Secure bool `yaml:"secure" json:"secure"` Frontends map[string]*Frontend `yaml:"frontends" json:"frontends"` }
Binding struct
type ConfigWatcher ¶
type ConfigWatcher struct {
// contains filtered or unexported fields
}
ConfigWatcher struct
func NewConfigWatcher ¶
func NewConfigWatcher() (*ConfigWatcher, error)
NewConfigWatcher creates new file watcher for config files
type Configuration ¶
Configuration map
func NewConfiguration ¶
func NewConfiguration() Configuration
NewConfiguration returns a new Configuration
func (Configuration) ParseFile ¶
func (c Configuration) ParseFile(confPath string) error
ParseFile func
func (Configuration) SetDefaultsAndValidate ¶
func (c Configuration) SetDefaultsAndValidate() error
SetDefaultsAndValidate sets defaults and validates
type Frontend ¶
type Frontend struct { Name string `yaml:"-" json:"-"` BoundAddr string `yaml:"-" json:"-"` Backends []Backend `yaml:"backends" json:"backends"` Strategy string `yaml:"strategy" json:"strategy"` Autocert bool `yaml:"autocert" json:"autocert"` TLSCrt string `yaml:"tls_crt" json:"tlsCrt"` TLSKey string `yaml:"tls_key" json:"tlsKey"` }
Frontend struct
func NewFrontend ¶
NewFrontend returns a new Configuration
func (*Frontend) SetDefaultsAndValidate ¶
SetDefaultsAndValidate sets defaults and validates
Click to show internal directories.
Click to hide internal directories.