mlboperator

package
v0.0.0-...-c1ead0e Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package v1beta1 contains API Schema definitions for the metallb v1beta1 API group +kubebuilder:object:generate=true +groupName=metallb.io

Index

Constants

This section is empty.

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "metallb.io", Version: "v1beta1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var ExternalFRRK8sNamespace string

Functions

This section is empty.

Types

type BGPType

type BGPType string
const (
	FRRMode            BGPType = "frr"
	NativeMode         BGPType = "native"
	FRRK8sMode         BGPType = "frr-k8s"
	FRRK8sExternalMode BGPType = "frr-k8s-external"
)

type Config

type Config struct {
	// Define priority class name
	// +optional
	PriorityClassName string `json:"priorityClassName,omitempty"`

	// Define container runtime configuration class
	// +optional
	RuntimeClassName string `json:"runtimeClassName,omitempty"`

	// If specified, the pod's scheduling constraints
	// +optional
	Affinity *corev1.Affinity `json:"affinity,omitempty"`

	// Annotations to be applied for MetalLB Operator
	// +optional
	Annotations map[string]string `json:"annotations,omitempty"`

	// Resource Requirements to be applied for containers which gets deployed
	// via MetalLB Operator
	// +optional
	Resources *corev1.ResourceRequirements `json:"resources,omitempty"`
}

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 FRRK8SConfig

type FRRK8SConfig struct {
	// A list of cidrs we want always to block for incoming routes
	AlwaysBlock []string `json:"alwaysBlock,omitempty"`
	// The namespace frr-k8s is running on in case of frr-k8s external mode
	Namespace string `json:"namespace,omitempty"`
}

func (*FRRK8SConfig) DeepCopy

func (in *FRRK8SConfig) DeepCopy() *FRRK8SConfig

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

func (*FRRK8SConfig) DeepCopyInto

func (in *FRRK8SConfig) DeepCopyInto(out *FRRK8SConfig)

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

type MetalLB

type MetalLB struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   MetalLBSpec   `json:"spec,omitempty"`
	Status MetalLBStatus `json:"status,omitempty"`
}

MetalLB is the Schema for the metallbs API

func (*MetalLB) DeepCopy

func (in *MetalLB) DeepCopy() *MetalLB

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

func (*MetalLB) DeepCopyInto

func (in *MetalLB) DeepCopyInto(out *MetalLB)

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

func (*MetalLB) DeepCopyObject

func (in *MetalLB) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*MetalLB) SetupWebhookWithManager

func (metallb *MetalLB) SetupWebhookWithManager(mgr ctrl.Manager, externalFRRK8sNamespace string) error

func (*MetalLB) Validate

func (metallb *MetalLB) Validate() error

func (*MetalLB) ValidateCreate

func (metallb *MetalLB) ValidateCreate() (admission.Warnings, error)

ValidateCreate implements webhook.Validator so a webhook will be registered for MetalLB.

func (*MetalLB) ValidateDelete

func (metallb *MetalLB) ValidateDelete() (admission.Warnings, error)

ValidateDelete implements webhook.Validator so a webhook will be registered for MetalLB.

func (*MetalLB) ValidateUpdate

func (metallb *MetalLB) ValidateUpdate(old runtime.Object) (admission.Warnings, error)

ValidateUpdate implements webhook.Validator so a webhook will be registered for MetalLB.

type MetalLBList

type MetalLBList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []MetalLB `json:"items"`
}

MetalLBList contains a list of MetalLB

func (*MetalLBList) DeepCopy

func (in *MetalLBList) DeepCopy() *MetalLBList

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

func (*MetalLBList) DeepCopyInto

func (in *MetalLBList) DeepCopyInto(out *MetalLBList)

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

func (*MetalLBList) DeepCopyObject

func (in *MetalLBList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type MetalLBLogLevel

type MetalLBLogLevel string
const (
	LogLevelAll   MetalLBLogLevel = "all"
	LogLevelDebug MetalLBLogLevel = "debug"
	LogLevelInfo  MetalLBLogLevel = "info"
	LogLevelWarn  MetalLBLogLevel = "warn"
	LogLevelError MetalLBLogLevel = "error"
	LogLevelNone  MetalLBLogLevel = "none"
)

These are valid logging level for MetalLB components.

type MetalLBSpec

type MetalLBSpec struct {

	// Foo is an example field of MetalLB. Edit MetalLB_types.go to remove/update
	MetalLBImage string `json:"image,omitempty"`

	// node selector applied to MetalLB speaker daemonset.
	// +optional
	SpeakerNodeSelector map[string]string `json:"nodeSelector,omitempty"`

	// tolerations is a list of tolerations applied to MetalLB speaker
	// daemonset.
	// +optional
	SpeakerTolerations []corev1.Toleration `json:"speakerTolerations,omitempty"`

	// Define the verbosity of the controller and the speaker logging.
	// Allowed values are: all, debug, info, warn, error, none. (default: info)
	// +optional
	// +kubebuilder:validation:Enum=all;debug;info;warn;error;none
	LogLevel MetalLBLogLevel `json:"logLevel,omitempty"`

	// The loadBalancerClass spec attribute that the MetalLB controller should
	// be watching for. must be a label-style identifier, with an optional
	// prefix such as "internal-vip" or "example.com/internal-vip". Unprefixed
	// names are reserved for end-users.
	// +optional
	// +kubebuilder:validation:Pattern=`^([a-z0-9A-Z]([\w.\-]*[a-z0-9A-Z])?/)?[a-z0-9A-Z]([\w.\-]*[a-z0-9A-Z])?$`
	LoadBalancerClass string `json:"loadBalancerClass,omitempty"`

	// node selector applied to MetalLB controller deployment.
	// +optional
	ControllerNodeSelector map[string]string `json:"controllerNodeSelector,omitempty"`

	// tolerations is a list of tolerations applied to MetalLB controller
	// deployment.
	// +optional
	ControllerTolerations []corev1.Toleration `json:"controllerTolerations,omitempty"`

	// additional configs to be applied on MetalLB Controller deployment.
	// +optional
	ControllerConfig *Config `json:"controllerConfig,omitempty"`

	// additional configs to be applied on MetalLB Speaker daemonset.
	// +optional
	SpeakerConfig *Config `json:"speakerConfig,omitempty"`

	// The type of BGP implementation deployed with MetalLB
	// +optional
	BGPBackend BGPType `json:"bgpBackend,omitempty"`

	// The specific frr-k8s configuration
	FRRK8SConfig *FRRK8SConfig `json:"frrk8sConfig,omitempty"`
}

MetalLBSpec defines the desired state of MetalLB

func (*MetalLBSpec) DeepCopy

func (in *MetalLBSpec) DeepCopy() *MetalLBSpec

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

func (*MetalLBSpec) DeepCopyInto

func (in *MetalLBSpec) DeepCopyInto(out *MetalLBSpec)

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

type MetalLBStatus

type MetalLBStatus struct {

	// Conditions show the current state of the MetalLB Operator
	Conditions []metav1.Condition `json:"conditions,omitempty"`
}

MetalLBStatus defines the observed state of MetalLB

func (*MetalLBStatus) DeepCopy

func (in *MetalLBStatus) DeepCopy() *MetalLBStatus

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

func (*MetalLBStatus) DeepCopyInto

func (in *MetalLBStatus) DeepCopyInto(out *MetalLBStatus)

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

Jump to

Keyboard shortcuts

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