Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadConfig ¶
func LoadConfig()
Types ¶
type InfluxbConfig ¶
type NadaServeConfig ¶
type NadaServeConfig struct { Port int `koanf:"port" validate:"required"` LogLevel zerolog.Level `koanf:"loglevel" validate:"omitempty,required"` InfluxDb InfluxbConfig `koanf:"influxdb" validate:"required"` AllowedOrigins []string `koanf:"allowedorigins" validate:"required"` Sensors map[string]SensorConfig `koanf:"sensors" validate:"required,min=1"` // we need at least one sensor available in config }
var CurrentConfig NadaServeConfig
type SensorConfig ¶
type SensorConfig struct { MeasurementName string `koanf:"name" validate:"required"` MeasurementUnit string `koanf:"unit" validate:"required"` }
func GetSensorConfig ¶
func GetSensorConfig(sensorType string) SensorConfig
Click to show internal directories.
Click to hide internal directories.