featureconfig

package
v1.20.1 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FeatureConfigFile = "/etc/config/config.yaml"
	CanaryFeature     = "canary"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthFeatureConfig added in v1.16.0

type AuthFeatureConfig struct {
	IsEnabled     bool          `json:"enabled"`
	AuthUriPath   string        `json:"authUriPath"`
	JWTExpiryTime time.Duration `json:"jwtExpiryTime"`
	JWTIssuer     string        `json:"jwtIssuer"`
}

type CanaryFeatureConfig

type CanaryFeatureConfig struct {
	IsEnabled     bool   `json:"enabled"`
	PrometheusSvc string `json:"prometheusSvc"`
}

specific feature config

type FeatureConfig

type FeatureConfig struct {
	// In the future more such feature configs can be added here for each optional feature
	CanaryConfig CanaryFeatureConfig `json:"canary"`
	AuthConfig   AuthFeatureConfig   `json:"auth"`
}

func GetFeatureConfig

func GetFeatureConfig(logger *zap.Logger) (*FeatureConfig, error)

GetFeatureConfig reads the configMap file and unmarshals the config into a feature config struct

Jump to

Keyboard shortcuts

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