config

package
v0.42.0 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2024 License: Apache-2.0 Imports: 14 Imported by: 2

Documentation

Overview

Package config holds the typed objects that define the schemas for assorted ConfigMap objects on which the Ingress controller depends.

Index

Constants

View Source
const (
	// ContourConfigName is the name of the configmap containing all
	// customizations for contour related features.
	ContourConfigName = "config-contour"
)

Variables

This section is empty.

Functions

func ToContext

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

ToContext adds config to given context.

Types

type Config

type Config struct {
	Contour *Contour
	Network *netconfig.Config
}

Config of Contour.

func FromContext

func FromContext(ctx context.Context) *Config

FromContext fetch config from context.

func (*Config) DeepCopy

func (in *Config) DeepCopy() *Config

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

func (*Config) DeepCopyInto

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

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

type Contour

type Contour struct {
	VisibilityKeys        map[v1alpha1.IngressVisibility]sets.Set[string]
	VisibilityClasses     map[v1alpha1.IngressVisibility]string
	DefaultTLSSecret      *types.NamespacedName
	TimeoutPolicyResponse string
	TimeoutPolicyIdle     string
	CORSPolicy            *v1.CORSPolicy
}

Contour contains contour related configuration defined in the contour config map.

func NewContourFromConfigMap

func NewContourFromConfigMap(configMap *corev1.ConfigMap) (*Contour, error)

NewContourFromConfigMap creates a Contour config from the supplied ConfigMap

func (*Contour) DeepCopy

func (in *Contour) DeepCopy() *Contour

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

func (*Contour) DeepCopyInto

func (in *Contour) DeepCopyInto(out *Contour)

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 configmap.UntypedStore based config store. +k8s:deepcopy-gen=false

func NewStore

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

NewStore creates a configmap.UntypedStore based config store.

logger must be non-nil implementation of configmap.Logger (commonly used loggers conform)

onAfterStore is a variadic list of callbacks to run after the ConfigMap has been processed and stored.

See also: configmap.NewUntypedStore().

func (*Store) Load

func (s *Store) Load() *Config

Load fetches config from Store.

func (*Store) ToContext

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

ToContext adds Store contents to given context.

Jump to

Keyboard shortcuts

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