Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ReadConfigFile ¶
ReadConfigFile reads the config file and overrides any values net in both it and the DefaultConfig
func ReadEnvironment ¶
func ReadEnvironment(cfg *Config)
ReadEnvironment overrides any configs set with settings from the environment
Types ¶
type Config ¶
type Config struct { // Server settings Address string `yaml:"address" envconfig:"address"` Port int `yaml:"port" envconfig:"port"` // Logger settings LogLevel string `yaml:"loglevel" envconfig:"loglevel"` LogFormat string `yaml:"logformat" envconfig:"logformat"` // CrawlInterval in seconds CrawlInterval int `yaml:"crawl_interval" envconfig:"crawlinterval"` // AWS settings AWSRegion string `yaml:"aws_region" envconfig:"awsregion"` // Service settings // - Owner of the service. For example the team running it. // Defaulted to the current user. Owner string `yaml:"owner" envconfig:"owner"` }
Config struct holds the current configuration
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig returns a Config struct with default values
Click to show internal directories.
Click to hide internal directories.