controller

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Dec 28, 2022 License: Apache-2.0, MIT Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ActuatorName is only used for the logger instance
	ActuatorName       = "acl-actuator"
	ResourceNameSeed   = "acl-seed"
	ChartNameSeed      = "seed"
	IngressNamespace   = "istio-ingress"
	HashAnnotationName = "acl-ext-rule-hash"
	// ImageName is used for the image vector override.
	// This is currently not implemented correctly.
	// TODO implement
	ImageName = "image-name"

	OpenstackTypeName = "openstack"
)
View Source
const (
	// Type is the type of Extension resource.
	Type   = "acl"
	Suffix = "-extension-service"
)

Variables

View Source
var (
	ErrSpecAction             = errors.New("action must either be 'ALLOW' or 'DENY'")
	ErrSpecRule               = errors.New("rule must be present")
	ErrSpecType               = errors.New("type must either be 'direct_remote_ip', 'remote_ip' or 'source_ip'")
	ErrSpecCIDR               = errors.New("CIDRs must not be empty")
	ErrNoExtensionsFound      = errors.New("could not list any extensions")
	ErrNoAdvertisedAddresses  = errors.New("advertised addresses are not available, likely because cluster creation has not yet completed")
	ErrProviderStatusRawIsNil = errors.New("providerStatus.Raw is nil, and can't be unmarshalled")
)
View Source
var (
	// DefaultAddOptions are the default AddOptions for AddToManager.
	DefaultAddOptions = AddOptions{}
)

Functions

func AddToManager

func AddToManager(mgr manager.Manager) error

AddToManager adds a controller with the default Options to the given Controller Manager.

func AddToManagerWithOptions

func AddToManagerWithOptions(mgr manager.Manager, opts *AddOptions) error

AddToManagerWithOptions adds a controller with the given Options to the given manager. The opts.Reconciler is being set with a newly instantiated actuator.

func ConfigureProviderSpecificAllowedCIDRs added in v0.2.0

func ConfigureProviderSpecificAllowedCIDRs(
	ctx context.Context,
	infra *extensionsv1alpha1.Infrastructure,
	alwaysAllowedCIDRs *[]string,
) error

func HashData

func HashData(data interface{}) (string, error)

HashData returns a 16 char hash for the given object.

func NewActuator

func NewActuator(cfg config.Config) extension.Actuator

NewActuator returns an actuator responsible for Extension resources.

func ValidateExtensionSpec

func ValidateExtensionSpec(spec *ExtensionSpec) error

Types

type AddOptions

type AddOptions struct {
	// ControllerOptions contains options for the controller.
	ControllerOptions controller.Options
	// ExtensionConfig contains configuration for the extension service
	ExtensionConfig controllerconfig.Config
	// IgnoreOperationAnnotation specifies whether to ignore the operation annotation or not.
	IgnoreOperationAnnotation bool
}

AddOptions are options to apply when adding the shoot service controller to the manager.

type ExtensionSpec

type ExtensionSpec struct {
	// Rule contain the user-defined Access Control Rule
	Rule *envoyfilters.ACLRule `json:"rule"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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