Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RenderConfig ¶
func RenderConfig(config *InitConfig) error
Types ¶
type Config ¶
type Config struct {
ListenAddr string `yaml:"listen_address"`
Verbose bool `yaml:"verbose"`
TLSKey string `yaml:"tls_key"`
TLSCrt string `yaml:"tls_crt"`
Commands []*command.Command `yaml:"commands"`
}
Config represents the configuration for this program
func ReadConfig ¶
readConfig reads configuration from supported means (cli flags, config file), validates parameters and returns a Config struct.
type ConsulConfig ¶
type ConsulConfig struct {
Address string
}
type InitCommand ¶
type InitCommand struct {
Cmd string `yaml:"cmd"`
Args []string `yaml:"args,omitempty"`
MatchLabels map[string]string `yaml:"match_labels,omitempty"`
NotifyOnFailure bool `yaml:"notify_on_failure"`
ResolvedSignal string `yaml:"resolved_signal,omitempty"`
IgnoreResolved bool `yaml:"ignore_resolved,omitempty"`
Max int `yaml:"max,omitempty"`
}
type InitConfig ¶
func LoadConfig ¶
func LoadConfig(configPath string) (*InitConfig, error)
type Server ¶
type Server struct {
Listen string
DataDir string
LogLevel string
TerraformDriver string
Consul ConsulConfig
}
type YAMLConfig ¶
type YAMLConfig struct {
ListenAddress string `yaml:"listen_address"`
Verbose bool `yaml:"verbose"`
TLSKey string `yaml:"tls_key,omitempty"`
TLSCrt string `yaml:"tls_crt,omitempty"`
Commands []InitCommand `yaml:"commands"`
}
Click to show internal directories.
Click to hide internal directories.