config

package
v0.36.2 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToContext

func ToContext(ctx context.Context, c *Config) context.Context

ToContext persists the configuration to the context.

Types

type Config

type Config struct {
	Kourier *config.Kourier
	Network *netconfig.Config
}

Config contains the configmaps requires for revision reconciliation. +k8s:deepcopy-gen=false

func FromContext

func FromContext(ctx context.Context) *Config

FromContext loads the configuration from the context.

func FromContextOrDefaults

func FromContextOrDefaults(ctx context.Context) *Config

func (*Config) DeepCopy added in v0.31.0

func (in *Config) DeepCopy() *Config

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Config.

func (*Config) DeepCopyInto added in v0.31.0

func (in *Config) DeepCopyInto(out *Config)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Store

type Store struct {
	*configmap.UntypedStore
}

Store is a typed wrapper around configmap.UntypedStore to handle our configmaps. +k8s:deepcopy-gen=false

func NewStore

func NewStore(logger configmap.Logger, onAfterStore ...func(name string, value interface{})) *Store

NewStore creates a new store of Configs and optionally calls functions when ConfigMaps are updated for Revisions

func (*Store) Load

func (s *Store) Load() *Config

Load returns the config from the store.

func (*Store) ToContext

func (s *Store) ToContext(ctx context.Context) context.Context

ToContext persists the config on the context.

Jump to

Keyboard shortcuts

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