Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Listen ListenConfig `hcl:"listen"` Sites []SiteConfig `hcl:"site"` Metric MetricConfig `hcl:"metric"` Logger LoggerConfig `hcl:"logger"` Consul ConsulConfig `hcl:"consul"` }
Config models the application's configuration
func LoadConfig ¶
type ConsulConfig ¶
type LabelConfig ¶
type LabelConfig struct { Name string `hcl:"label_name"` Source string `hcl:"source"` FixedValue string `hcl:"fixed_value"` Rules []RuleConfig `hcl:"rules"` }
type ListenConfig ¶
ListenConfig is a struct describing the built-in webserver configuration
type LoggerConfig ¶
type MetricConfig ¶
type RuleConfig ¶
type SiteConfig ¶
type SiteConfig struct { Name string `hcl:",key"` LogsDir string `hcl:"logs_dir"` Pattern string `hcl:"pattern"` LabelRules []LabelConfig `hcl:"label_rules"` }
type StartupFlags ¶
type StartupFlags struct {
ConfigFile string
}
StartupFlags is a struct containing filename option that can be passed via the command line
Click to show internal directories.
Click to hide internal directories.