v1alpha1

package
v1.6.1-0...-f207c0f Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the common v1alpha1 API group. +kubebuilder:object:generate=true

Index

Constants

View Source
const (
	// ControlPlaneRefKonnectID is the type for the KonnectID ControlPlaneRef.
	// It is used to reference a Konnect Control Plane entity by its ID on the Konnect platform.
	ControlPlaneRefKonnectID = "konnectID"
	// ControlPlaneRefKonnectNamespacedRef is the type for the KonnectNamespacedRef ControlPlaneRef.
	// It is used to reference a Konnect Control Plane entity inside the cluster
	// using a namespaced reference.
	ControlPlaneRefKonnectNamespacedRef = "konnectNamespacedRef"
	// ControlPlaneRefKIC is the type for KIC ControlPlaneRef.
	// It is used to reference a KIC as Control Plane.
	ControlPlaneRefKIC = "kic"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ControlPlaneRef

type ControlPlaneRef struct {
	// Type indicates the type of the control plane being referenced. Allowed values:
	// - konnectID
	// - konnectNamespacedRef
	// - kic
	//
	// The default is kic, which implies that the Control Plane is KIC.
	//
	// +optional
	// +kubebuilder:validation:Enum=konnectID;konnectNamespacedRef;kic
	// +kubebuilder:default:=kic
	Type string `json:"type,omitempty"`

	// KonnectID is the schema for the KonnectID type.
	// This field is required when the Type is konnectID.
	// +optional
	KonnectID *KonnectIDType `json:"konnectID,omitempty"`

	// KonnectNamespacedRef is a reference to a Konnect Control Plane entity inside the cluster.
	// It contains the name of the Konnect Control Plane.
	// This field is required when the Type is konnectNamespacedRef.
	// +optional
	KonnectNamespacedRef *KonnectNamespacedRef `json:"konnectNamespacedRef,omitempty"`
}

ControlPlaneRef is the schema for the ControlPlaneRef type. It is used to reference a Control Plane entity.

+kubebuilder:object:generate=true +kubebuilder:validation:XValidation:rule="(has(self.type) && self.type == 'konnectNamespacedRef') ? has(self.konnectNamespacedRef) : true", message="when type is konnectNamespacedRef, konnectNamespacedRef must be set" +kubebuilder:validation:XValidation:rule="(has(self.type) && self.type == 'konnectNamespacedRef') ? !has(self.konnectID) : true", message="when type is konnectNamespacedRef, konnectID must not be set" +kubebuilder:validation:XValidation:rule="(has(self.type) && self.type == 'konnectID') ? has(self.konnectID) : true", message="when type is konnectID, konnectID must be set" +kubebuilder:validation:XValidation:rule="(has(self.type) && self.type == 'konnectID') ? !has(self.konnectNamespacedRef) : true", message="when type is konnectID, konnectNamespacedRef must not be set" +kubebuilder:validation:XValidation:rule="(has(self.type) && self.type == 'kic') ? !has(self.konnectID) : true", message="when type is kic, konnectID must not be set" +kubebuilder:validation:XValidation:rule="(has(self.type) && self.type == 'kic') ? !has(self.konnectNamespacedRef) : true", message="when type is kic, konnectNamespacedRef must not be set" +kubebuilder:validation:XValidation:rule="!has(self.type) ? !has(self.konnectID) : true", message="when type is unset, konnectID must not be set" +kubebuilder:validation:XValidation:rule="!has(self.type) ? !has(self.konnectNamespacedRef) : true", message="when type is unset, konnectNamespacedRef must not be set" +apireference:kgo:include

func (*ControlPlaneRef) DeepCopy

func (in *ControlPlaneRef) DeepCopy() *ControlPlaneRef

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

func (*ControlPlaneRef) DeepCopyInto

func (in *ControlPlaneRef) DeepCopyInto(out *ControlPlaneRef)

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

func (*ControlPlaneRef) String

func (r *ControlPlaneRef) String() string

type EntitySource

type EntitySource string

EntitySource is the type for all the entity types.

const (
	// EntitySourceOrigin is the type for Origin entities.
	// Origin entities are the source of truth for the data.
	EntitySourceOrigin EntitySource = "Origin"
	// EntitySourceMirror is the type for Mirror entities.
	// Mirror entities are local mirrors of the remote konnect resource.
	EntitySourceMirror EntitySource = "Mirror"
)

type ExtensionRef

type ExtensionRef struct {
	// Group is the group of the extension resource.
	//
	// +optional
	// +kubebuilder:default=gateway-operator.konghq.com
	Group string `json:"group"`

	// Kind is kind of the extension resource.
	//
	// +required
	Kind string `json:"kind"`

	// NamespacedRef is a reference to the extension resource.
	NamespacedRef `json:",inline"`
}

ExtensionRef corresponds to another resource in the Kubernetes cluster which defines extended behavior for a resource (e.g. ControlPlane). +apireference:kgo:include

func (*ExtensionRef) DeepCopy

func (in *ExtensionRef) DeepCopy() *ExtensionRef

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

func (*ExtensionRef) DeepCopyInto

func (in *ExtensionRef) DeepCopyInto(out *ExtensionRef)

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

type KonnectExtensionControlPlaneRef

type KonnectExtensionControlPlaneRef struct {
	// Type indicates the type of the control plane being referenced. Allowed values:
	// - konnectNamespacedRef
	//
	// +optional
	// +kubebuilder:validation:Enum=konnectNamespacedRef
	// +kubebuilder:default:=konnectNamespacedRef
	Type string `json:"type,omitempty"`

	// KonnectNamespacedRef is a reference to a Konnect Control Plane entity inside the cluster.
	// It contains the name of the Konnect Control Plane.
	// This field is required when the Type is konnectNamespacedRef.
	// +optional
	KonnectNamespacedRef *KonnectNamespacedRef `json:"konnectNamespacedRef,omitempty"`
}

KonnectExtensionControlPlaneRef is the schema for the ControlPlaneRef type used by Konnect Extensions. It is used to reference a Control Plane entity.

+kubebuilder:object:generate=true +kubebuilder:validation:XValidation:rule="(has(self.type) && self.type == 'konnectNamespacedRef') ? has(self.konnectNamespacedRef) : true", message="when type is konnectNamespacedRef, konnectNamespacedRef must be set" +apireference:kgo:include

func (*KonnectExtensionControlPlaneRef) DeepCopy

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

func (*KonnectExtensionControlPlaneRef) DeepCopyInto

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

type KonnectIDType

type KonnectIDType string

KonnectIDType is the schema for the KonnectID type.

+kubebuilder:validation:Pattern=`^[0-9a-f]{8}(?:\-[0-9a-f]{4}){3}-[0-9a-f]{12}$`

type KonnectNamespacedRef

type KonnectNamespacedRef struct {
	// Name is the name of the Konnect Control Plane.
	// +required
	Name string `json:"name"`

	// Namespace is the namespace where the Konnect Control Plane is in.
	// Currently only cluster scoped resources (KongVault) are allowed to set `konnectNamespacedRef.namespace`.
	//
	// +optional
	Namespace string `json:"namespace,omitempty"`
}

KonnectNamespacedRef is the schema for the KonnectNamespacedRef type.

+kubebuilder:object:generate=true +apireference:kgo:include

func (*KonnectNamespacedRef) DeepCopy

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

func (*KonnectNamespacedRef) DeepCopyInto

func (in *KonnectNamespacedRef) DeepCopyInto(out *KonnectNamespacedRef)

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

type NameRef

type NameRef struct {
	// Name is the name of the entity.
	//
	// +required
	// +kubebuilder:validation:MinLength=1
	Name string `json:"name"`
}

NameRef is a reference to another object representing a Kong entity with deterministic type.

+apireference:kgo:include

func (*NameRef) DeepCopy

func (in *NameRef) DeepCopy() *NameRef

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

func (*NameRef) DeepCopyInto

func (in *NameRef) DeepCopyInto(out *NameRef)

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

type NamespacedRef

type NamespacedRef struct {
	// Name is the name of the referred resource.
	//
	// +required
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=253
	Name string `json:"name"`

	// Namespace is the namespace of the referred resource.
	//
	// For namespace-scoped resources if no Namespace is provided then the
	// namespace of the parent object MUST be used.
	//
	// This field MUST not be set when referring to cluster-scoped resources.
	//
	// +optional
	Namespace *string `json:"namespace,omitempty"`
}

NamespacedRef is a reference to a namespaced resource.

+apireference:kgo:include

func (*NamespacedRef) DeepCopy

func (in *NamespacedRef) DeepCopy() *NamespacedRef

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

func (*NamespacedRef) DeepCopyInto

func (in *NamespacedRef) DeepCopyInto(out *NamespacedRef)

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

type ObjectRef

type ObjectRef struct {
	// Type defines type of the object which is referenced. It can be one of:
	//
	// - konnectID
	// - namespacedRef
	//
	// +required
	Type ObjectRefType `json:"type"`

	// KonnectID is the schema for the KonnectID type.
	// This field is required when the Type is konnectID.
	//
	// +optional
	KonnectID *string `json:"konnectID,omitempty"`

	// NamespacedRef is a reference to a KeySet entity inside the cluster.
	// This field is required when the Type is namespacedRef.
	//
	// +optional
	NamespacedRef *NamespacedRef `json:"namespacedRef,omitempty"`
}

ObjectRef is the schema for the ObjectRef type. It is used to reference an entity. Currently it is possible to reference a remote Konnect entity by its ID or a local in cluster entity by its namespaced name.

+kubebuilder:validation:XValidation:rule="self.type == 'namespacedRef' ? has(self.namespacedRef) : true", message="when type is namespacedRef, namespacedRef must be set" +kubebuilder:validation:XValidation:rule="self.type == 'namespacedRef' ? !has(self.konnectID) : true", message="when type is namespacedRef, konnectID must not be set" +kubebuilder:validation:XValidation:rule="self.type == 'konnectID' ? has(self.konnectID) : true", message="when type is konnectID, konnectID must be set" +kubebuilder:validation:XValidation:rule="self.type == 'konnectID' ? !has(self.namespacedRef) : true", message="when type is konnectID, namespacedRef must not be set" +apireference:kgo:include +kong:channels=gateway-operator

func (*ObjectRef) DeepCopy

func (in *ObjectRef) DeepCopy() *ObjectRef

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

func (*ObjectRef) DeepCopyInto

func (in *ObjectRef) DeepCopyInto(out *ObjectRef)

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

type ObjectRefType

type ObjectRefType string

ObjectRefType is the enum type for the ObjectRef.

+kubebuilder:validation:Enum=konnectID;namespacedRef +apireference:kgo:include

const (
	// ObjectRefTypeKonnectID is the type for the KonnectID KonnectRef.
	// It is used to reference an entity by its ID on the Konnect platform.
	ObjectRefTypeKonnectID ObjectRefType = "konnectID"

	// ObjectRefTypeNamespacedRef is the type for the KonnectRef.
	// It is used to reference an entity inside the cluster
	// using a namespaced reference.
	ObjectRefTypeNamespacedRef ObjectRefType = "namespacedRef"
)

type Tags

type Tags []string

Tags is a type for a list of tags applied to a Kong entity. +kubebuilder:validation:MaxItems=20 +kubebuilder:validation:XValidation:message="tags entries must not be longer than 128 characters", rule="self.all(tag, size(tag) >= 1 && size(tag) <= 128)"

func (Tags) DeepCopy

func (in Tags) DeepCopy() Tags

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

func (Tags) DeepCopyInto

func (in Tags) DeepCopyInto(out *Tags)

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