config

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2023 License: Apache-2.0 Imports: 1 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Event

type Event struct {
	// Key possible values
	// "" - reset the whole config
	// "batch" - set global and modules config at once
	// "global" - set only global config
	// "<moduleName> - set only config for the module <moduleName>
	Key    string
	Config *KubeConfig
	Err    error
}

type GlobalKubeConfig

type GlobalKubeConfig struct {
	Values   utils.Values
	Checksum string
}

func ParseGlobalKubeConfigFromValues

func ParseGlobalKubeConfigFromValues(values utils.Values) (*GlobalKubeConfig, error)

func (GlobalKubeConfig) GetValues

func (gkc GlobalKubeConfig) GetValues() utils.Values

GetValues returns global values, enrich them with top level key 'global'

TODO: since we have specified struct for global values, we don't need to encapsulate them into the map {"global": ... }

but we have to change this behavior somewhere in the module-manager

type KubeConfig

type KubeConfig struct {
	Global  *GlobalKubeConfig
	Modules map[string]*ModuleKubeConfig
}

func NewConfig

func NewConfig() *KubeConfig

type KubeConfigEvent

type KubeConfigEvent string
const (
	KubeConfigChanged KubeConfigEvent = "Changed"
	KubeConfigInvalid KubeConfigEvent = "Invalid"
)

type ModuleKubeConfig

type ModuleKubeConfig struct {
	utils.ModuleConfig
	Checksum string
}

func ParseModuleKubeConfigFromValues

func ParseModuleKubeConfigFromValues(moduleName string, values utils.Values) *ModuleKubeConfig

Jump to

Keyboard shortcuts

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