Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetBeaconConfigDefaults ¶ added in v1.3.0
func SetBeaconConfigDefaults(c *ExtensionConfig)
func SetConfigDefaults ¶
func SetConfigDefaults(c *ExtensionConfig) error
SetConfigDefaults sets default values if not present ExtensionConfig.Name must be set before calling this function
func SetHAProxyConfigDefaults ¶ added in v1.1.1
func SetHAProxyConfigDefaults(c *ExtensionConfig)
func SetNginxConfigDefaults ¶ added in v1.1.1
func SetNginxConfigDefaults(c *ExtensionConfig)
Types ¶
type Config ¶
type Config struct {
ListenAddr string
DockerURL string
TLSCACert string
TLSCert string
TLSKey string
AllowInsecure bool
EnableMetrics bool
PollInterval string
Extensions []*ExtensionConfig
Rules map[string]*Rule // beacon TODO: move to ExtensionConfig
}
Config is the top level configuration
func ParseConfig ¶
ParseConfig returns a Config object from a raw string config TOML
type ExtensionConfig ¶
type ExtensionConfig struct {
Name string // extension name
ConfigPath string // config file path
ConfigBasePath string `toml:"-"` // internal
PidPath string // haproxy, nginx
TemplatePath string // template file path
BackendOverrideAddress string // haproxy, nginx
ConnectTimeout int // haproxy
ServerTimeout int // haproxy
ClientTimeout int // haproxy
MaxConn int // haproxy, nginx
Port int // haproxy, nginx
SyslogAddr string // haproxy
AdminUser string // haproxy
AdminPass string // haproxy
SSLCertPath string // haproxy, nginx
SSLCert string // haproxy
SSLPort int // haproxy, nginx
SSLOpts string // haproxy
SSLDefaultDHParam int // haproxy
SSLServerVerify string // haproxy
DHParam bool // nginx
DHParamPath string // nginx
NginxPlusEnabled bool // nginx
User string // nginx
WorkerProcesses int // nginx
RLimitNoFile int // nginx
ProxyConnectTimeout int // nginx
ProxySendTimeout int // nginx
ProxyReadTimeout int // nginx
SendTimeout int // nginx
SSLCiphers string // nginx
SSLProtocols string // nginx
StatsInterval string // beacon
StatsBackendType string // beacon (influxdb, prometheus)
StatsPrometheusPushGatewayURL string // beacon (prometheus)
StatsInfluxDBAddress string // beacon (influxdb)
StatsInfluxDBUser string // beacon (influxdb user)
StatsInfluxDBPassword string // beacon (influxdb password)
StatsInfluxDBDatabase string // beacon (influxdb)
StatsInfluxDBPrecision string // beacon (influxdb)
Rules map[string]*Rule // beacon FIXME: this isn't loaded properly from toml; we set it as a hack now
}
ExtensionConfig has all options for all load balancer extensions the extension itself will use whichever options needed
Click to show internal directories.
Click to hide internal directories.