config

package
v1.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 16, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrAuthDetailsMissing = errors.New("auth credentials missing")

Functions

This section is empty.

Types

type Config

type Config struct {
	Debug        bool `envconfig:"DEBUG" default:"true"`
	InfluxConfig *InfluxConfig
	K8sConfig    *K8sConfig
}

func LoadConfig

func LoadConfig() (*Config, error)

type InfluxConfig

type InfluxConfig struct {
	InfluxDbUrl  string `envconfig:"INFLUXDB_URL" default:"http://localhost:8087"`
	InfluxDbName string `envconfig:"INFLUXDB_NAME" default:"rkm-outpost"`
	InfluxDbUser string `envconfig:"INFLUXDB_USER" default:""`
	InfluxDbPW   string `envconfig:"INFLUXDB_PW" default:""`
	AuthEnabled  bool   `envconfig:"AUTH_ENABLED" default:"false"`
}

type K8sConfig

type K8sConfig struct {
	ClusterName string `envconfig:"CLUSTER_NAME" default:"k8sdev"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL