config

package
v0.0.0-...-7799e87 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2020 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultApiListenAddress = "0.0.0.0:1337"
View Source
const DefaultLogLevel = "ERROR"
View Source
const DefaultShutdownTimeoutSeconds = 30
View Source
const DefaultUaaAudienceClaim = "config_server"
View Source
const DefaultUaaConnectionTimeoutSeconds = 10
View Source
const DefaultUaaKeyRefreshIntervalSeconds = 86400
View Source
const DefaultVaultConnectionTimeoutSeconds = 30
View Source
const DefaultVaultMount = "secret"

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	Api struct {
		Address      string `json:"address" yaml:"address"`
		DrainTimeout int    `json:"draintimeout" yaml:"draintimeout"`
	} `json:"api" yaml:"api"`
	Log struct {
		Level string `json:"level" yaml:"level"`
	} `json:"log" yaml:"log"`
	Tls struct {
		Cert string `json:"cert" yaml:"key"`
		Key  string `json:"key" yaml:"key"`
	} `json:"tls" yaml:"tls"`
	Redirects []RedirectBlock    `json:"redirects" yaml:"redirects"`
	Uaa       UaaConfiguration   `json:"uaa" yaml:"uaa"`
	Vault     VaultConfiguration `json:"vault" yaml:"vault"`
	Debug     DebugConfiguration `json:"debug" yaml:"debug"`
}

func ParseConfig

func ParseConfig(configFilePath *string) Configuration

type DebugConfiguration

type DebugConfiguration struct {
	DisableAuth bool `json:"disable_auth" yaml:"disable_auth"`
	DisableTls  bool `json:"disable_tls" yaml:"disable_tls"`
}

type RedirectBlock

type RedirectBlock struct {
	Type  string             `json:"type" yaml:"type"`
	Vault VaultConfiguration `json:"vault" yaml:"vault"`
	Rules []RedirectRule     `json:"rules" yaml:"rules"`
}

type RedirectRule

type RedirectRule struct {
	Ref      string `json:"ref" yaml:"ref"`
	Redirect string `json:"redirect" yaml:"redirect"`
}

type UaaConfiguration

type UaaConfiguration struct {
	Address               string `json:"address" yaml:"address"`
	Timeout               int    `json:"timeout" yaml:"timeout"`
	Ca                    string `json:"ca" yaml:"ca"`
	SkipVerify            bool   `json:"skipverify" yaml:"skipverify"`
	ExpectedAudienceClaim string `json:"audienceclaim"`
	KeyRefreshInterval    int    `json:"keyrefreshinterval" yaml:"keyrefreshinterval"`
}

type VaultConfiguration

type VaultConfiguration struct {
	Address         string `json:"address" yaml:"address"`
	Token           string `json:"token" yaml:"token"`
	Timeout         int    `json:"timeout" yaml:"timeout"`
	Mount           string `json:"mount" yaml:"mount"`
	Ca              string `json:"ca" yaml:"ca"`
	SkipVerify      bool   `json:"skipverify" yaml:"skipverify"`
	RenewalInterval int    `json:"renewalinterval" yaml:"renewalinterval"`
}

Jump to

Keyboard shortcuts

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