config

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Version = `v0.0.1-experimental` // should be overridden by build process, ldflags

Version is the current version of the application

Functions

func SetDefaults

func SetDefaults(v *viper.Viper)

SetDefaults applies default values to viper

Types

type Config

type Config struct {
	REST     RESTConfig      `mapstructure:"rest"`
	Pipeline pipeline.Config `mapstructure:"pipeline"`
}

Config holds application-wide configuration

func Load

func Load(cfgFile string) (*Config, error)

Load reads config from file or environment

type OIDCConfig

type OIDCConfig struct {
	ClientID      string `mapstructure:"clientID"`
	ClientSecret  string `mapstructure:"clientSecret"`
	Issuer        string `mapstructure:"issuer"`
	SkipTLSVerify bool   `mapstructure:"skipTLSVerify"`
	RoleClaimKey  string `mapstructure:"roleClaimKey"`
}

type PGConfig

type PGConfig struct {
	ConnString string `mapstructure:"connString"`
}

type RESTConfig

type RESTConfig struct {
	PG         PGConfig          `mapstructure:"pg"`
	ListenAddr string            `mapstructure:"listenAddr"`
	BaseURL    string            `mapstructure:"baseURL"`
	OIDC       OIDCConfig        `mapstructure:"oidc"`
	BasicAuth  map[string]string `mapstructure:"basicAuth"`
	AnonRole   string            `mapstructure:"anonRole"`
	Omitempty  bool              `mapstructure:"omitempty"`
}

Jump to

Keyboard shortcuts

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