config

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OIDCConfig

type OIDCConfig struct {
	Address string `yaml:"address"`

	ClusterName            string   `yaml:"clusterName"`
	IssuerURL              string   `yaml:"issuerURL"`
	ClientID               string   `yaml:"clientID"`
	ClientSecret           string   `yaml:"clientSecret"`
	AllowEmptyClientSecret bool     `yaml:"allowEmptyClientSecret"`
	RedirectURL            string   `yaml:"redirectURL"`  // http://gangway.auth.app.local:9080
	RedirectPath           string   `yaml:"redirectPath"` // /callback
	Scopes                 []string `yaml:"scopes"`
	UsernameClaim          string   `yaml:"usernameClaim"`
	EmailClaim             string   `yaml:"emailClaim"`
	ServeTLS               bool     `yaml:"serveTLS"`
	Audience               string   `yaml:"audience"`
	CacheTimeout           int32    `yaml:"cacheTimeout"`
	SkipIssuerCheck        bool     `yaml:"skipIssuerCheck"`

	// T decide wether should this be use
	SessionSecurityKey string `yaml:"sessionSecurityKey" envconfig:"SESSION_SECURITY_KEY"`
}

OIDCConfig defines the configuration parameters uses to configure the OIDC provider.

func NewConfig

func NewConfig(configFile string) (*OIDCConfig, error)

NewConfig returns a Config struct from serialized config file.

func (*OIDCConfig) Validate

func (cfg *OIDCConfig) Validate() error

Validate verifies all properties of config struct are initialized.

Jump to

Keyboard shortcuts

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