Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultConfig = Config{ Web: webOptions{ ListenAddress: "0.0.0.0:9201", TelemetryPath: "/metrics", }, Read: readOptions{ Timeout: 5 * time.Minute, Delay: 1 * time.Hour, IgnoreError: true, }, Write: writeOptions{ Timeout: 5 * time.Minute, }, Graphite: graphite.DefaultConfig, }
DefaultConfig is the default top-level configuration.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { ConfigFile string LogLevel promlog.AllowedLevel Web webOptions `yaml:"web,omitempty" json:"web,omitempty"` Read readOptions `yaml:"read,omitempty" json:"read,omitempty"` Write writeOptions `yaml:"write,omitempty" json:"write,omitempty"` Graphite graphite.Config `yaml:"graphite,omitempty" json:"graphite,omitempty"` // Catches all undefined fields and must be empty after parsing. XXX map[string]interface{} `yaml:",inline" json:"-"` // contains filtered or unexported fields }
Config is the top-level configuration.
func ParseCommandLine ¶
func ParseCommandLine() *Config
ParseCommandLine parse flags and args from cli.
func (*Config) UnmarshalYAML ¶
UnmarshalYAML implements the yaml.Unmarshaler interface.
Click to show internal directories.
Click to hide internal directories.