v1beta1

package
v1.0.0-alpha.4 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2022 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Overview

Package v1beta1 contains API Schema definitions for the infrastructure v1beta1 API group +kubebuilder:object:generate=true +groupName=infrastructure.cluster.x-k8s.io

Index

Constants

View Source
const (
	// NetworkReadyCondition reports on the successful reconciliation of a Network.
	NetworkReadyCondition clusterv1.ConditionType = "NetworkReady"
	// NetworkCreationStartedReason used when attempting to create a Network for a managed cluster.
	// Will not be applied to unmanaged clusters.
	NetworkCreationStartedReason = "NetworkCreationStarted"
	// NetworkReconciliationFailedReason used when errors occur during Network reconciliation.
	NetworkReconciliationFailedReason = "NetworkReconciliationFailed"
)
View Source
const (
	// SubnetsReadyCondition reports on the successful reconciliation of subnets.
	SubnetsReadyCondition clusterv1.ConditionType = "SubnetsReady"
	// SubnetsReconciliationFailedReason used to report failures while reconciling subnets.
	SubnetsReconciliationFailedReason = "SubnetsReconciliationFailed"
)
View Source
const (
	// LoadBalancerReadyCondition reports on whether a control plane load balancer was successfully reconciled.
	LoadBalancerReadyCondition clusterv1.ConditionType = "LoadBalancerReady"
	// WaitForDNSNameReason used while waiting for a DNS name for the API server to be populated.
	WaitForDNSNameReason = "WaitForDNSName"
	// WaitForDNSNameResolveReason used while waiting for DNS name to resolve.
	WaitForDNSNameResolveReason = "WaitForDNSNameResolve"
	// LoadBalancerFailedReason used when an error occurs during load balancer reconciliation.
	LoadBalancerFailedReason = "LoadBalancerFailed"
)
View Source
const (
	// LoadBalancerAttachedToNetworkCondition reports on whether the load balancer is attached to a network.
	LoadBalancerAttachedToNetworkCondition clusterv1.ConditionType = "LoadBalancerAttachedToNetwork"
	// LoadBalancerAttachFailedReason is used when load balancer could not be attached to network.
	LoadBalancerAttachFailedReason = "LoadBalancerAttachFailed"
	// LoadBalancerNoNetworkFoundReason is used when load balancer could not be attached to network.
	LoadBalancerNoNetworkFoundReason = "LoadBalancerNoNetworkFound"
)
View Source
const (
	// InstanceReadyCondition reports on current status of the instance. Ready indicates the instance is in a Running state.
	InstanceReadyCondition clusterv1.ConditionType = "InstanceReady"
	// InstanceNotFoundReason used when the instance couldn't be retrieved.
	InstanceNotFoundReason = "InstanceNotFound"
	// InstanceTerminatedReason instance is in a terminated state.
	InstanceTerminatedReason = "InstanceTerminated"
	// InstanceStoppedReason instance is in a stopped state.
	InstanceStoppedReason = "InstanceStopped"
	// InstanceNotReadyReason used when the instance is in a pending state.
	InstanceNotReadyReason = "InstanceNotReady"
	// InstanceProvisionStartedReason set when the provisioning of an instance started.
	InstanceProvisionStartedReason = "InstanceProvisionStarted"
	// InstanceProvisionFailedReason used for failures during instance provisioning.
	InstanceProvisionFailedReason = "InstanceProvisionFailed"
	// WaitingForClusterInfrastructureReason used when machine is waiting for cluster infrastructure to be ready before proceeding.
	WaitingForClusterInfrastructureReason = "WaitingForClusterInfrastructure"
	// WaitingForBootstrapDataReason used when machine is waiting for bootstrap data to be ready before proceeding.
	WaitingForBootstrapDataReason = "WaitingForBootstrapData"
)
View Source
const (
	// LBAttachedCondition will report true when a control plane is successfully registered with an LB.
	// Only applicable to control plane machines.
	LBAttachedCondition clusterv1.ConditionType = "LBAttached"
	// LBAttachFailedReason used when a control plane node fails to attach to the ELB.
	LBAttachFailedReason = "LBAttachFailed"
	// LBDetachFailedReason used when a control plane node fails to detach from an ELB.
	LBDetachFailedReason = "LBDetachFailed"
)
View Source
const (
	// ClusterFinalizer allows ReconcileHetznerCluster to clean up HCloud
	// resources associated with HetznerCluster before removing it from the
	// apiserver.
	ClusterFinalizer = "hetznercluster.infrastructure.cluster.x-k8s.io"

	// LoadBalancerAlgorithmTypeRoundRobin default for the Kubernetes Api Server loadbalancer.
	LoadBalancerAlgorithmTypeRoundRobin = LoadBalancerAlgorithmType("round_robin")

	// LoadBalancerAlgorithmTypeLeastConnections default for Loadbalancer.
	LoadBalancerAlgorithmTypeLeastConnections = LoadBalancerAlgorithmType("least_connections")
)
View Source
const (
	// ResourceLifecycleOwned is the value we use when tagging resources to indicate
	// that the resource is considered owned and managed by the cluster,
	// and in particular that the lifecycle is tied to the lifecycle of the cluster.
	ResourceLifecycleOwned = ResourceLifecycle("owned")

	// ResourceLifecycleShared is the value we use when tagging resources to indicate
	// that the resource is shared between multiple clusters, and should not be destroyed
	// if the cluster is destroyed.
	ResourceLifecycleShared = ResourceLifecycle("shared")

	// NameKubernetesHetznerCloudProviderPrefix is the tag name used by the cloud provider to logically
	// separate independent cluster resources. We use it to identify which resources we expect
	// to be permissive about state changes.
	// logically independent clusters running in the same AZ.
	// The tag key = NameKubernetesHetznerCloudProviderPrefix + clusterID
	// The tag value is an ownership value.
	NameKubernetesHetznerCloudProviderPrefix = "caph"

	// NameHetznerProviderPrefix is the tag prefix we use to differentiate
	// cluster-api-provider-hetzner owned components from other tooling that
	// uses NameKubernetesClusterPrefix
	// NameHetznerProviderPrefix = "sigs.k8s.io/cluster-api-provider-hetzner/".
	NameHetznerProviderPrefix = "caph-"
	// NameHetznerProviderOwned is the tag name we use to differentiate
	// cluster-api-provider-hetzner owned components from other tooling that
	// uses NameKubernetesClusterPrefix.
	NameHetznerProviderOwned = NameHetznerProviderPrefix + "cluster-"

	// MachineNameTagKey tags related MachineNameTag.
	MachineNameTagKey = "machine." + NameHetznerProviderPrefix + "name"

	// MachineTemplateHashTagKey tags server resources.
	MachineTemplateHashTagKey = "machine." + NameHetznerProviderPrefix + "template"
)
View Source
const (
	// MachineFinalizer allows ReconcileHCloudMachine to clean up HCloud
	// resources associated with HCloudMachine before removing it from the
	// apiserver.
	MachineFinalizer = "hcloudmachine.infrastructure.cluster.x-k8s.io"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects.
	GroupVersion = schema.GroupVersion{Group: "infrastructure.cluster.x-k8s.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
)

Functions

func ClusterHetznerCloudProviderTagKey

func ClusterHetznerCloudProviderTagKey(name string) string

ClusterHetznerCloudProviderTagKey generates the key for resources associated a cluster's HCloud cloud provider.

func ClusterTagKey

func ClusterTagKey(name string) string

ClusterTagKey generates the key for resources associated with a cluster.

Types

type HCloudMachine

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

	Spec   HCloudMachineSpec   `json:"spec,omitempty"`
	Status HCloudMachineStatus `json:"status,omitempty"`
}

HCloudMachine is the Schema for the hcloudmachines API.

func (*HCloudMachine) DeepCopy

func (in *HCloudMachine) DeepCopy() *HCloudMachine

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

func (*HCloudMachine) DeepCopyInto

func (in *HCloudMachine) DeepCopyInto(out *HCloudMachine)

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

func (*HCloudMachine) DeepCopyObject

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

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

func (*HCloudMachine) Default

func (r *HCloudMachine) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type.

func (*HCloudMachine) GetConditions

func (r *HCloudMachine) GetConditions() clusterv1.Conditions

GetConditions returns the observations of the operational state of the HCloudMachine resource.

func (*HCloudMachine) HCloudMachineSpec

func (r *HCloudMachine) HCloudMachineSpec() *HCloudMachineSpec

HCloudMachineSpec returns a DeepCopy.

func (*HCloudMachine) Hub

func (*HCloudMachine) Hub()

Hub marks HCloudMachine as a conversion hub.

func (*HCloudMachine) SetConditions

func (r *HCloudMachine) SetConditions(conditions clusterv1.Conditions)

SetConditions sets the underlying service state of the HCloudMachine to the predescribed clusterv1.Conditions.

func (*HCloudMachine) SetupWebhookWithManager

func (r *HCloudMachine) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager initializes webhook manager for HCloudMachine.

func (*HCloudMachine) ValidateCreate

func (r *HCloudMachine) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type.

func (*HCloudMachine) ValidateDelete

func (r *HCloudMachine) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type.

func (*HCloudMachine) ValidateUpdate

func (r *HCloudMachine) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type.

type HCloudMachineList

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

HCloudMachineList contains a list of HCloudMachine.

func (*HCloudMachineList) DeepCopy

func (in *HCloudMachineList) DeepCopy() *HCloudMachineList

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

func (*HCloudMachineList) DeepCopyInto

func (in *HCloudMachineList) DeepCopyInto(out *HCloudMachineList)

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

func (*HCloudMachineList) DeepCopyObject

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

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

func (*HCloudMachineList) Hub

func (*HCloudMachineList) Hub()

Hub marks HCloudMachineList as a conversion hub.

func (*HCloudMachineList) SetupWebhookWithManager

func (r *HCloudMachineList) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager initializes webhook manager for HCloudMachineList.

type HCloudMachineSpec

type HCloudMachineSpec struct {
	// ProviderID is the unique identifier as specified by the cloud provider.
	// +optional
	ProviderID *string `json:"providerID,omitempty"`

	// Type is the HCloud Machine Type for this machine.
	// +kubebuilder:validation:Enum=cpx11;cx21;cpx21;cx31;cpx31;cx41;cpx41;cx51;cpx51;ccx11;ccx12;ccx21;ccx22;ccx31;ccx32;ccx41;ccx42;ccx51;ccx52;ccx62;
	Type HCloudMachineTypeSpec `json:"type"`

	// ImageName is the reference to the Machine Image from which to create the machine instance.
	ImageName string `json:"imageName"`

	// define Machine specific SSH keys, overrides cluster wide SSH keys
	// +optional
	SSHKey []SSHKeySpec `json:"sshKeys,omitempty"`

	// +optional
	PlacementGroupName *string `json:"placementGroupName,omitempty"`
}

HCloudMachineSpec defines the desired state of HCloudMachine.

func (*HCloudMachineSpec) DeepCopy

func (in *HCloudMachineSpec) DeepCopy() *HCloudMachineSpec

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

func (*HCloudMachineSpec) DeepCopyInto

func (in *HCloudMachineSpec) DeepCopyInto(out *HCloudMachineSpec)

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

type HCloudMachineStatus

type HCloudMachineStatus struct {
	// Ready is true when the provider resource is ready.
	// +optional
	Ready bool `json:"ready"`

	// Addresses contains the server's associated addresses.
	Addresses []corev1.NodeAddress `json:"addresses,omitempty"`

	Region Region `json:"region,omitempty"`

	// InstanceState is the state of the server for this machine.
	// +optional
	InstanceState *hcloud.ServerStatus `json:"instanceState,omitempty"`

	// FailureReason will be set in the event that there is a terminal problem
	// reconciling the Machine and will contain a succinct value suitable
	// for machine interpretation.
	// +optional
	FailureReason *errors.MachineStatusError `json:"failureReason,omitempty"`

	// FailureMessage will be set in the event that there is a terminal problem
	// reconciling the Machine and will contain a more verbose string suitable
	// for logging and human consumption.
	// +optional
	FailureMessage *string `json:"failureMessage,omitempty"`

	// Conditions defines current service state of the HCloudMachine.
	// +optional
	Conditions clusterv1.Conditions `json:"conditions,omitempty"`
}

HCloudMachineStatus defines the observed state of HCloudMachine.

func (*HCloudMachineStatus) DeepCopy

func (in *HCloudMachineStatus) DeepCopy() *HCloudMachineStatus

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

func (*HCloudMachineStatus) DeepCopyInto

func (in *HCloudMachineStatus) DeepCopyInto(out *HCloudMachineStatus)

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

type HCloudMachineTemplate

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

	Spec HCloudMachineTemplateSpec `json:"spec,omitempty"`
}

HCloudMachineTemplate is the Schema for the hcloudmachinetemplates API.

func (*HCloudMachineTemplate) DeepCopy

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

func (*HCloudMachineTemplate) DeepCopyInto

func (in *HCloudMachineTemplate) DeepCopyInto(out *HCloudMachineTemplate)

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

func (*HCloudMachineTemplate) DeepCopyObject

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

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

func (*HCloudMachineTemplate) Default

func (r *HCloudMachineTemplate) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type.

func (*HCloudMachineTemplate) Hub

func (*HCloudMachineTemplate) Hub()

Hub marks HCloudMachineTemplate as a conversion hub.

func (*HCloudMachineTemplate) SetupWebhookWithManager

func (r *HCloudMachineTemplate) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager initializes webhook manager for HetznerMachineTemplate.

func (*HCloudMachineTemplate) ValidateCreate

func (r *HCloudMachineTemplate) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type.

func (*HCloudMachineTemplate) ValidateDelete

func (r *HCloudMachineTemplate) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type.

func (*HCloudMachineTemplate) ValidateUpdate

func (r *HCloudMachineTemplate) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type.

type HCloudMachineTemplateList

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

HCloudMachineTemplateList contains a list of HCloudMachineTemplate.

func (*HCloudMachineTemplateList) DeepCopy

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

func (*HCloudMachineTemplateList) DeepCopyInto

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

func (*HCloudMachineTemplateList) DeepCopyObject

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

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

func (*HCloudMachineTemplateList) Hub

Hub marks HCloudMachineTemplateList as a conversion hub.

func (*HCloudMachineTemplateList) SetupWebhookWithManager

func (r *HCloudMachineTemplateList) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager initializes webhook manager for HetznerMachineTemplateList.

type HCloudMachineTemplateResource

type HCloudMachineTemplateResource struct {
	// Standard object's metadata.
	// +optional
	ObjectMeta clusterv1.ObjectMeta `json:"metadata,omitempty"`

	// Spec is the specification of the desired behavior of the machine.
	Spec HCloudMachineSpec `json:"spec"`
}

HCloudMachineTemplateResource describes the data needed to create am HCloudMachine from a template.

func (*HCloudMachineTemplateResource) DeepCopy

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

func (*HCloudMachineTemplateResource) DeepCopyInto

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

type HCloudMachineTemplateSpec

type HCloudMachineTemplateSpec struct {
	Template HCloudMachineTemplateResource `json:"template"`
}

HCloudMachineTemplateSpec defines the desired state of HCloudMachineTemplate.

func (*HCloudMachineTemplateSpec) DeepCopy

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

func (*HCloudMachineTemplateSpec) DeepCopyInto

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

type HCloudMachineTypeSpec

type HCloudMachineTypeSpec string

HCloudMachineTypeSpec defines the HCloud Machine type.

type HCloudNetworkSpec

type HCloudNetworkSpec struct {
	NetworkEnabled bool `json:"enabled"`

	// Defines the cidrBlock of the HCloud Network. A Subnet is required.
	// +kubebuilder:default="10.0.0.0/16"
	CIDRBlock string `json:"cidrBlock,omitempty"`

	// +kubebuilder:default="10.0.0.0/24"
	SubnetCIDRBlock string `json:"subnetCidrBlock,omitempty"`

	// +kubebuilder:default=eu-central
	NetworkZone HCloudNetworkZone `json:"networkZone,omitempty"`
}

HCloudNetworkSpec defines the desired state of the HCloud Private Network.

func (*HCloudNetworkSpec) DeepCopy

func (in *HCloudNetworkSpec) DeepCopy() *HCloudNetworkSpec

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

func (*HCloudNetworkSpec) DeepCopyInto

func (in *HCloudNetworkSpec) DeepCopyInto(out *HCloudNetworkSpec)

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

func (*HCloudNetworkSpec) IsZero

func (s *HCloudNetworkSpec) IsZero() bool

IsZero return if a private Network is set or not.

type HCloudNetworkZone

type HCloudNetworkZone string

HCloudNetworkZone describes the Network zone.

type HCloudPlacementGroupSpec

type HCloudPlacementGroupSpec struct {
	Name string `json:"name,omitempty"`
	// +kubebuilder:validation:Enum=spread
	Type string `json:"type,omitempty"`
}

HCloudPlacementGroupSpec defines a PlacementGroup.

func (*HCloudPlacementGroupSpec) DeepCopy

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

func (*HCloudPlacementGroupSpec) DeepCopyInto

func (in *HCloudPlacementGroupSpec) DeepCopyInto(out *HCloudPlacementGroupSpec)

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

type HCloudPlacementGroupStatus

type HCloudPlacementGroupStatus struct {
	ID     int    `json:"id,omitempty"`
	Server []int  `json:"servers,omitempty"`
	Name   string `json:"name,omitempty"`
	Type   string `json:"type,omitempty"`
}

HCloudPlacementGroupStatus returns the status of a Placementgroup.

func (*HCloudPlacementGroupStatus) DeepCopy

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

func (*HCloudPlacementGroupStatus) DeepCopyInto

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

type HetznerCluster

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

	Spec   HetznerClusterSpec   `json:"spec,omitempty"`
	Status HetznerClusterStatus `json:"status,omitempty"`
}

HetznerCluster is the Schema for the hetznercluster API.

func (*HetznerCluster) DeepCopy

func (in *HetznerCluster) DeepCopy() *HetznerCluster

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

func (*HetznerCluster) DeepCopyInto

func (in *HetznerCluster) DeepCopyInto(out *HetznerCluster)

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

func (*HetznerCluster) DeepCopyObject

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

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

func (*HetznerCluster) Default

func (r *HetznerCluster) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type.

func (*HetznerCluster) GetConditions

func (r *HetznerCluster) GetConditions() clusterv1.Conditions

GetConditions returns the observations of the operational state of the HetznerCluster resource.

func (*HetznerCluster) Hub

func (*HetznerCluster) Hub()

Hub marks HetznerCluster as a conversion hub.

func (*HetznerCluster) SetConditions

func (r *HetznerCluster) SetConditions(conditions clusterv1.Conditions)

SetConditions sets the underlying service state of the HetznerCluster to the predescribed clusterv1.Conditions.

func (*HetznerCluster) SetupWebhookWithManager

func (r *HetznerCluster) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager initializes webhook manager for HetznerCluster.

func (*HetznerCluster) ValidateCreate

func (r *HetznerCluster) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type.

func (*HetznerCluster) ValidateDelete

func (r *HetznerCluster) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type.

func (*HetznerCluster) ValidateUpdate

func (r *HetznerCluster) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type.

type HetznerClusterList

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

HetznerClusterList contains a list of HetznerCluster +kubebuilder:object:root=true +k8s:defaulter-gen=true

func (*HetznerClusterList) DeepCopy

func (in *HetznerClusterList) DeepCopy() *HetznerClusterList

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

func (*HetznerClusterList) DeepCopyInto

func (in *HetznerClusterList) DeepCopyInto(out *HetznerClusterList)

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

func (*HetznerClusterList) DeepCopyObject

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

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

func (*HetznerClusterList) Hub

func (*HetznerClusterList) Hub()

Hub marks HetznerClusterList as a conversion hub.

func (*HetznerClusterList) SetupWebhookWithManager

func (r *HetznerClusterList) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager initializes webhook manager for HetznerClusterList.

type HetznerClusterSpec

type HetznerClusterSpec struct {
	// HCloudNetworkSpec defines the Network for Hetzner Cloud. If left empty no private Network is configured.
	// +optional
	HCloudNetworkSpec HCloudNetworkSpec `json:"hcloudNetwork"`

	// ControlPlaneRegion consists of a list of HCloud Regions (fsn, nbg, hel). Because HCloud Networks
	// have a very low latency we could assume in some use-cases that a region is behaving like a zone
	// https://kubernetes.io/docs/reference/labels-annotations-taints/#topologykubernetesiozone
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:default={fsn1}
	ControlPlaneRegion []Region `json:"controlPlaneRegions"`

	// define cluster wide SSH keys. Valid values are a valid SSH key name, or a valid ID.
	SSHKey []SSHKeySpec `json:"sshKeys,omitempty"`
	// ControlPlaneEndpoint represents the endpoint used to communicate with the control plane.
	// +optional
	ControlPlaneEndpoint *clusterv1.APIEndpoint `json:"controlPlaneEndpoint"`

	// ControlPlaneLoadBalancer is optional configuration for customizing control plane behavior. Naming convention is from upstream cluster-api project.
	// +optional
	ControlPlaneLoadBalancer LoadBalancerSpec `json:"controlPlaneLoadBalancer,omitempty"`

	// +optional
	HCloudPlacementGroupSpec []HCloudPlacementGroupSpec `json:"hcloudPlacementGroups,omitempty"`

	// HetznerSecretRef is a reference to a token to be used when reconciling this cluster.
	// This is generated in the Security section under API TOKENS. Read & Write is necessary.
	HetznerSecretRef HetznerSecretRef `json:"hetznerSecretRef"`
}

HetznerClusterSpec defines the desired state of HetznerCluster.

func (*HetznerClusterSpec) DeepCopy

func (in *HetznerClusterSpec) DeepCopy() *HetznerClusterSpec

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

func (*HetznerClusterSpec) DeepCopyInto

func (in *HetznerClusterSpec) DeepCopyInto(out *HetznerClusterSpec)

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

type HetznerClusterStatus

type HetznerClusterStatus struct {
	// +kubebuilder:default=false
	Ready bool `json:"ready"`

	// +optional
	Network *NetworkStatus `json:"networkStatus,omitempty"`

	ControlPlaneLoadBalancer *LoadBalancerStatus `json:"controlPlaneLoadBalancer,omitempty"`
	// +optional
	HCloudPlacementGroup []HCloudPlacementGroupStatus `json:"hcloudPlacementGroups,omitempty"`
	FailureDomains       clusterv1.FailureDomains     `json:"failureDomains,omitempty"`
	Conditions           clusterv1.Conditions         `json:"conditions,omitempty"`
}

HetznerClusterStatus defines the observed state of HetznerCluster.

func (*HetznerClusterStatus) DeepCopy

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

func (*HetznerClusterStatus) DeepCopyInto

func (in *HetznerClusterStatus) DeepCopyInto(out *HetznerClusterStatus)

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

type HetznerClusterTemplate

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

	Spec HetznerClusterTemplateSpec `json:"spec,omitempty"`
}

HetznerClusterTemplate is the Schema for the hetznerclustertemplates API.

func (*HetznerClusterTemplate) DeepCopy

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

func (*HetznerClusterTemplate) DeepCopyInto

func (in *HetznerClusterTemplate) DeepCopyInto(out *HetznerClusterTemplate)

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

func (*HetznerClusterTemplate) DeepCopyObject

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

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

func (*HetznerClusterTemplate) Default

func (r *HetznerClusterTemplate) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type.

func (*HetznerClusterTemplate) SetupWebhookWithManager

func (r *HetznerClusterTemplate) SetupWebhookWithManager(mgr ctrl.Manager) error

SetupWebhookWithManager initializes webhook manager for HetznerClusterTemplate.

func (*HetznerClusterTemplate) ValidateCreate

func (r *HetznerClusterTemplate) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type.

func (*HetznerClusterTemplate) ValidateDelete

func (r *HetznerClusterTemplate) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type.

func (*HetznerClusterTemplate) ValidateUpdate

func (r *HetznerClusterTemplate) ValidateUpdate(oldRaw runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type.

type HetznerClusterTemplateList

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

HetznerClusterTemplateList contains a list of HetznerClusterTemplate.

func (*HetznerClusterTemplateList) DeepCopy

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

func (*HetznerClusterTemplateList) DeepCopyInto

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

func (*HetznerClusterTemplateList) DeepCopyObject

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

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

type HetznerClusterTemplateResource

type HetznerClusterTemplateResource struct {
	// +optional
	ObjectMeta clusterv1.ObjectMeta `json:"metadata,omitempty"`
	Spec       HetznerClusterSpec   `json:"spec"`
}

HetznerClusterTemplateResource contains spec for HetznerClusterSpec.

func (*HetznerClusterTemplateResource) DeepCopy

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

func (*HetznerClusterTemplateResource) DeepCopyInto

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

type HetznerClusterTemplateSpec

type HetznerClusterTemplateSpec struct {
	Template HetznerClusterTemplateResource `json:"template"`
}

HetznerClusterTemplateSpec defines the desired state of HetznerClusterTemplate.

func (*HetznerClusterTemplateSpec) DeepCopy

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

func (*HetznerClusterTemplateSpec) DeepCopyInto

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

type HetznerSecretKeyRef

type HetznerSecretKeyRef struct {
	HCloudToken string `json:"hcloudToken"`
}

HetznerSecretKeyRef defines the key name of the HetznerSecret.

func (*HetznerSecretKeyRef) DeepCopy

func (in *HetznerSecretKeyRef) DeepCopy() *HetznerSecretKeyRef

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

func (*HetznerSecretKeyRef) DeepCopyInto

func (in *HetznerSecretKeyRef) DeepCopyInto(out *HetznerSecretKeyRef)

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

type HetznerSecretRef

type HetznerSecretRef struct {
	Name string              `json:"name"`
	Key  HetznerSecretKeyRef `json:"key"`
}

HetznerSecretRef defines all the name of the secret and the relevant keys needed to access Hetzner API.

func (*HetznerSecretRef) DeepCopy

func (in *HetznerSecretRef) DeepCopy() *HetznerSecretRef

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

func (*HetznerSecretRef) DeepCopyInto

func (in *HetznerSecretRef) DeepCopyInto(out *HetznerSecretRef)

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

type LoadBalancerAlgorithmType

type LoadBalancerAlgorithmType string

LoadBalancerAlgorithmType defines the Algorithm type. +kubebuilder:validation:Enum=round_robin;least_connections

type LoadBalancerSpec

type LoadBalancerSpec struct {
	// +optional
	Name *string `json:"name,omitempty"`

	// Could be round_robin or least_connection. The default value is "round_robin".
	// +optional
	// +kubebuilder:validation:Enum=round_robin;least_connections
	// +kubebuilder:default=round_robin
	Algorithm LoadBalancerAlgorithmType `json:"algorithm,omitempty"`

	// Loadbalancer type
	// +optional
	// +kubebuilder:validation:Enum=lb11;lb21;lb31
	// +kubebuilder:default=lb11
	Type string `json:"type,omitempty"`

	// API Server port. It must be valid ports range (1-65535). If omitted, default value is 6443.
	// +optional
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=65535
	// +kubebuilder:default=6443
	Port int `json:"port,omitempty"`

	// Defines how traffic will be routed from the Load Balancer to your target server.
	// +optional
	Targets []LoadBalancerTargetSpec `json:"extraTargets,omitempty"`

	Region Region `json:"region"`
}

LoadBalancerSpec defines the desired state of the Control Plane Loadbalancer.

func (*LoadBalancerSpec) DeepCopy

func (in *LoadBalancerSpec) DeepCopy() *LoadBalancerSpec

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

func (*LoadBalancerSpec) DeepCopyInto

func (in *LoadBalancerSpec) DeepCopyInto(out *LoadBalancerSpec)

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

type LoadBalancerStatus

type LoadBalancerStatus struct {
	ID         int    `json:"id,omitempty"`
	IPv4       string `json:"ipv4,omitempty"`
	IPv6       string `json:"ipv6,omitempty"`
	InternalIP string `json:"internalIP,omitempty"`
	Target     []int  `json:"targets,omitempty"`
	Protected  bool   `json:"protected,omitempty"`
}

LoadBalancerStatus defines the obeserved state of the control plane loadbalancer.

func (*LoadBalancerStatus) DeepCopy

func (in *LoadBalancerStatus) DeepCopy() *LoadBalancerStatus

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

func (*LoadBalancerStatus) DeepCopyInto

func (in *LoadBalancerStatus) DeepCopyInto(out *LoadBalancerStatus)

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

type LoadBalancerTargetSpec

type LoadBalancerTargetSpec struct {
	// Protocol specifies the supported Loadbalancer Protocol.
	// +optional
	// +kubebuilder:validation:Enum=http;https;tcp
	Protocol string `json:"protocol,omitempty"`

	// Equal Source port, defines the incoming port open on the loadbalancer
	// +optional
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=65535
	ListenPort int `json:"listenPort,omitempty"`

	// Defines the port on the server
	// +optional
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=65535
	DestinationPort int `json:"destinationPort,omitempty"`
}

LoadBalancerTargetSpec defines a Loadbalancer Target.

func (*LoadBalancerTargetSpec) DeepCopy

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

func (*LoadBalancerTargetSpec) DeepCopyInto

func (in *LoadBalancerTargetSpec) DeepCopyInto(out *LoadBalancerTargetSpec)

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

type NetworkStatus

type NetworkStatus struct {
	ID             int               `json:"id,omitempty"`
	Labels         map[string]string `json:"-"`
	AttachedServer []int             `json:"attachedServers,omitempty"`
}

NetworkStatus defines the observed state of the HCloud Private Network.

func (*NetworkStatus) DeepCopy

func (in *NetworkStatus) DeepCopy() *NetworkStatus

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

func (*NetworkStatus) DeepCopyInto

func (in *NetworkStatus) DeepCopyInto(out *NetworkStatus)

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

type Region

type Region string

Region is a Hetzner Location +kubebuilder:validation:Enum=fsn1;hel1;nbg1;ash

type ResourceLifecycle

type ResourceLifecycle string

ResourceLifecycle configures the lifecycle of a resource.

type SSHKeySpec

type SSHKeySpec struct {
	Name *string `json:"name,omitempty"`
	ID   *int    `json:"id,omitempty"`
}

SSHKeySpec defines the SSHKey.

func (*SSHKeySpec) DeepCopy

func (in *SSHKeySpec) DeepCopy() *SSHKeySpec

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

func (*SSHKeySpec) DeepCopyInto

func (in *SSHKeySpec) DeepCopyInto(out *SSHKeySpec)

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