v1beta2

package
v0.1.0-alpha.3 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

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

Index

Constants

View Source
const (
	// ReadyCondition indicates the overall readiness of the resource.
	// For CloudscaleCluster: True when all infrastructure is provisioned and endpoint is set.
	// For CloudscaleMachine: True when the server exists and is running.
	// This condition is mirrored by CAPI to the parent resource's InfrastructureReady condition.
	ReadyCondition = "Ready"

	// NetworkReadyCondition indicates whether the private network and subnet have been provisioned.
	// Only applicable to CloudscaleCluster.
	NetworkReadyCondition = "NetworkReady"

	// LoadBalancerReadyCondition indicates whether the load balancer and all its
	// components (pool, listener, health monitor) are ready.
	// Only applicable to CloudscaleCluster.
	LoadBalancerReadyCondition = "LoadBalancerReady"

	// ServerGroupReadyCondition indicates whether the server group has been provisioned.
	// Only applicable to CloudscaleMachine.
	ServerGroupReadyCondition = "ServerGroupReady"

	// ServerReadyCondition indicates whether the server has been provisioned.
	// Only applicable to CloudscaleMachine.
	ServerReadyCondition = "ServerReady"

	// PausedCondition indicates the resource reconciliation is paused.
	// True when the pause annotation is present on the resource or parent cluster.
	PausedCondition = "Paused"

	// DeletingCondition indicates the resource is being deleted.
	// True when DeletionTimestamp is set on the resource.
	DeletingCondition = "Deleting"
)

Condition types for CloudscaleCluster and CloudscaleMachine resources. These conditions follow the CAPI v1beta2 contract and Kubernetes API conventions.

View Source
const (
	// NetworkProvisionedReason indicates the network has been successfully provisioned.
	NetworkProvisionedReason = "NetworkProvisioned"

	// NetworkErrorReason indicates an error occurred during network operations.
	NetworkErrorReason = "NetworkError"

	// NetworkDeletingReason indicates the network is being deleted.
	NetworkDeletingReason = "NetworkDeleting"

	// LoadBalancerRunningReason indicates the load balancer is running and ready.
	LoadBalancerRunningReason = "LoadBalancerRunning"

	// LoadBalancerNotReadyReason indicates the load balancer exists but is not yet running.
	LoadBalancerNotReadyReason = "LoadBalancerNotReady"

	// LoadBalancerDisabledReason indicates the load balancer is disabled (external control plane).
	LoadBalancerDisabledReason = "LoadBalancerDisabled"

	// LoadBalancerErrorReason indicates an error occurred during load balancer operations.
	LoadBalancerErrorReason = "LoadBalancerError"

	// LoadBalancerDeletingReason indicates the load balancer is being deleted.
	LoadBalancerDeletingReason = "LoadBalancerDeleting"
)

Condition reasons for CloudscaleCluster.

View Source
const (
	// ServerRunningReason indicates the server is running and ready.
	ServerRunningReason = "ServerRunning"

	// ServerStartingReason indicates the server is being created (status: changing).
	ServerStartingReason = "ServerStarting"

	// ServerChangingReason indicates the server is transitioning (status: changing, after already provisioned).
	ServerChangingReason = "ServerChanging"

	// ServerStoppedReason indicates the server is stopped.
	ServerStoppedReason = "ServerStopped"

	// ServerInRescueModeReason indicates the server is in rescue mode.
	ServerInRescueModeReason = "ServerInRescueMode"

	// ServerInternalErrorReason indicates an internal error with the server (paused/error/unknown status).
	ServerInternalErrorReason = "ServerInternalError"

	// ServerErrorReason indicates an error occurred during server operations.
	ServerErrorReason = "ServerError"

	// ServerDeletingReason indicates the server is being deleted.
	ServerDeletingReason = "ServerDeleting"

	// ServerDeletedExternallyReason indicates the server was deleted outside of CAPI.
	ServerDeletedExternallyReason = "ServerDeletedExternally"

	// ServerGroupReadyReason indicates the server group has been successfully provisioned.
	ServerGroupReadyReason = "ServerGroupReady"

	// ServerGroupErrorReason indicates an error occurred during server group operations.
	ServerGroupErrorReason = "ServerGroupError"

	// WaitingForClusterInfrastructureReason indicates the machine is waiting for
	// the cluster infrastructure to be provisioned.
	WaitingForClusterInfrastructureReason = "WaitingForClusterInfrastructure"

	// WaitingForBootstrapDataReason indicates the machine is waiting for
	// bootstrap data to be available.
	WaitingForBootstrapDataReason = "WaitingForBootstrapData"
)

Condition reasons for CloudscaleMachine.

View Source
const (
	// DeletingReason indicates the resource is being deleted.
	DeletingReason = "Deleting"

	// PausedReason indicates the resource reconciliation is paused.
	PausedReason = "Paused"

	// ReadyReason indicates the resource is ready.
	ReadyReason = "Ready"

	// NotReadyReason indicates the resource is not ready.
	NotReadyReason = "NotReady"
)

Shared condition reasons.

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")

	// NameCloudscaleProviderPrefix is the tag prefix we use to differentiate
	// cluster-api-provider-cloudscale owned components from other tooling that
	// uses NameKubernetesClusterPrefix
	NameCloudscaleProviderPrefix = "capcs-"

	// NameCloudscaleProviderOwned is the tag name we use to differentiate
	// cluster-api-provider-cloudscale owned components from other tooling that
	// uses NameKubernetesClusterPrefix.
	NameCloudscaleProviderOwned = NameCloudscaleProviderPrefix + "cluster-"
)
View Source
const (
	// ClusterFinalizer allows cleanup of resources before removal from the API.
	ClusterFinalizer = "cloudscalecluster.infrastructure.cluster.x-k8s.io"
)
View Source
const (
	// MachineFinalizer allows cleanup of resources before removal from the API.
	MachineFinalizer = "cloudscalemachine.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: "v1beta2"}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = schemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type CloudscaleCluster

type CloudscaleCluster struct {
	metav1.TypeMeta `json:",inline"`

	// metadata is a standard object metadata
	// +optional
	metav1.ObjectMeta `json:"metadata,omitzero"`

	// spec defines the desired state of CloudscaleCluster
	// +required
	Spec CloudscaleClusterSpec `json:"spec"`

	// status defines the observed state of CloudscaleCluster
	// +optional
	Status CloudscaleClusterStatus `json:"status,omitzero"`
}

CloudscaleCluster is the Schema for the cloudscaleclusters API

func (*CloudscaleCluster) ClusterTagKey

func (c *CloudscaleCluster) ClusterTagKey() string

ClusterTagKey generates the key for resources associated with a cluster.

func (*CloudscaleCluster) CredentialsSecretRef

func (c *CloudscaleCluster) CredentialsSecretRef() corev1.ObjectReference

CredentialsSecretRef returns an ObjectReference to the credentials Secret.

func (*CloudscaleCluster) DeepCopy

func (in *CloudscaleCluster) DeepCopy() *CloudscaleCluster

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

func (*CloudscaleCluster) DeepCopyInto

func (in *CloudscaleCluster) DeepCopyInto(out *CloudscaleCluster)

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

func (*CloudscaleCluster) DeepCopyObject

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

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

func (*CloudscaleCluster) GetConditions

func (c *CloudscaleCluster) GetConditions() []metav1.Condition

GetConditions returns the conditions for the CloudscaleCluster. This implements the conditions.Getter interface from CAPI util/conditions.

func (*CloudscaleCluster) SetConditions

func (c *CloudscaleCluster) SetConditions(conds []metav1.Condition)

SetConditions sets the conditions for the CloudscaleCluster. This implements the conditions.Setter interface from CAPI util/conditions.

type CloudscaleClusterList

type CloudscaleClusterList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitzero"`
	Items           []CloudscaleCluster `json:"items"`
}

CloudscaleClusterList contains a list of CloudscaleCluster

func (*CloudscaleClusterList) DeepCopy

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

func (*CloudscaleClusterList) DeepCopyInto

func (in *CloudscaleClusterList) DeepCopyInto(out *CloudscaleClusterList)

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

func (*CloudscaleClusterList) DeepCopyObject

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

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

type CloudscaleClusterSpec

type CloudscaleClusterSpec struct {
	// Region is the cloudscale.ch region (e.g., "rma", "lpg").
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:Enum=rma;lpg
	Region string `json:"region"`

	// Zone is the cloudscale.ch zone (e.g., "rma1", "lpg1").
	// Defaults to region + "1" if not specified.
	// +optional
	Zone string `json:"zone,omitempty"`

	// CredentialsRef references the Secret containing the cloudscale.ch API token.
	// +kubebuilder:validation:Required
	CredentialsRef CloudscaleCredentialsReference `json:"credentialsRef"`

	// ControlPlaneEndpoint represents the endpoint to communicate with the control plane.
	// This is set automatically from the load balancer's VIP address.
	// +optional
	ControlPlaneEndpoint clusterv1.APIEndpoint `json:"controlPlaneEndpoint,omitzero"`

	// Network contains network configuration for the cluster.
	// +optional
	Network NetworkSpec `json:"network,omitzero"`

	// ControlPlaneLoadBalancer configures the load balancer for the control plane.
	// +optional
	ControlPlaneLoadBalancer LoadBalancerSpec `json:"controlPlaneLoadBalancer,omitzero"`
}

CloudscaleClusterSpec defines the desired state of CloudscaleCluster

func (*CloudscaleClusterSpec) DeepCopy

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

func (*CloudscaleClusterSpec) DeepCopyInto

func (in *CloudscaleClusterSpec) DeepCopyInto(out *CloudscaleClusterSpec)

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

type CloudscaleClusterStatus

type CloudscaleClusterStatus struct {
	// Initialization contains v1beta2 initialization tracking.
	// +optional
	Initialization *ClusterInitializationStatus `json:"initialization,omitempty"`

	// NetworkID is the cloudscale.ch network UUID.
	// +optional
	NetworkID string `json:"networkID,omitempty"`

	// SubnetID is the cloudscale.ch subnet UUID.
	// +optional
	SubnetID string `json:"subnetID,omitempty"`

	// LoadBalancerID is the cloudscale.ch load balancer UUID.
	// +optional
	LoadBalancerID string `json:"loadBalancerID,omitempty"`

	// LoadBalancerPoolID is the cloudscale.ch load balancer pool UUID for the API server.
	// +optional
	LoadBalancerPoolID string `json:"loadBalancerPoolID,omitempty"`

	// LoadBalancerListenerID is the cloudscale.ch load balancer listener UUID for the API server.
	// +optional
	LoadBalancerListenerID string `json:"loadBalancerListenerID,omitempty"`

	// LoadBalancerHealthMonitorID is the cloudscale.ch load balancer health monitor UUID.
	// +optional
	LoadBalancerHealthMonitorID string `json:"loadBalancerHealthMonitorID,omitempty"`

	// LoadBalancerMemberIDs are the list of nodes attached to the loadBalancer.
	// +optional
	LoadBalancerMemberIDs []string `json:"loadBalancerMemberIDs,omitempty"`

	// conditions represent the current state of the CloudscaleCluster resource.
	// Each condition has a unique type and reflects the status of a specific aspect of the resource.
	//
	// Standard condition types include:
	// - "Available": the resource is fully functional
	// - "Progressing": the resource is being created or updated
	// - "Degraded": the resource failed to reach or maintain its desired state
	//
	// The status of each condition is one of True, False, or Unknown.
	// +listType=map
	// +listMapKey=type
	// +optional
	Conditions []metav1.Condition `json:"conditions,omitempty"`
}

CloudscaleClusterStatus defines the observed state of CloudscaleCluster.

func (*CloudscaleClusterStatus) DeepCopy

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

func (*CloudscaleClusterStatus) DeepCopyInto

func (in *CloudscaleClusterStatus) DeepCopyInto(out *CloudscaleClusterStatus)

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

type CloudscaleCredentialsReference

type CloudscaleCredentialsReference struct {
	// Name is the name of the Secret.
	// +kubebuilder:validation:Required
	Name string `json:"name"`

	// Namespace is the namespace of the Secret. Defaults to the cluster namespace.
	// +optional
	Namespace string `json:"namespace,omitempty"`
}

CloudscaleCredentialsReference references a Secret containing the API token.

func (*CloudscaleCredentialsReference) DeepCopy

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

func (*CloudscaleCredentialsReference) DeepCopyInto

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

type CloudscaleMachine

type CloudscaleMachine struct {
	metav1.TypeMeta `json:",inline"`

	// metadata is a standard object metadata
	// +optional
	metav1.ObjectMeta `json:"metadata,omitzero"`

	// spec defines the desired state of CloudscaleMachine
	// +required
	Spec CloudscaleMachineSpec `json:"spec"`

	// status defines the observed state of CloudscaleMachine
	// +optional
	Status CloudscaleMachineStatus `json:"status,omitzero"`
}

CloudscaleMachine is the Schema for the cloudscalemachines API

func (*CloudscaleMachine) DeepCopy

func (in *CloudscaleMachine) DeepCopy() *CloudscaleMachine

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

func (*CloudscaleMachine) DeepCopyInto

func (in *CloudscaleMachine) DeepCopyInto(out *CloudscaleMachine)

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

func (*CloudscaleMachine) DeepCopyObject

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

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

func (*CloudscaleMachine) GetConditions

func (m *CloudscaleMachine) GetConditions() []metav1.Condition

GetConditions returns the conditions for the CloudscaleMachine. This implements the conditions.Getter interface from CAPI util/conditions.

func (*CloudscaleMachine) MachineTagKey

func (m *CloudscaleMachine) MachineTagKey(clusterName string) string

MachineTagKey generates the tag key for machines associated with a cluster.

func (*CloudscaleMachine) SetConditions

func (m *CloudscaleMachine) SetConditions(cond []metav1.Condition)

SetConditions sets the conditions for the CloudscaleMachine. This implements the conditions.Setter interface from CAPI util/conditions.

type CloudscaleMachineList

type CloudscaleMachineList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitzero"`
	Items           []CloudscaleMachine `json:"items"`
}

CloudscaleMachineList contains a list of CloudscaleMachine

func (*CloudscaleMachineList) DeepCopy

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

func (*CloudscaleMachineList) DeepCopyInto

func (in *CloudscaleMachineList) DeepCopyInto(out *CloudscaleMachineList)

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

func (*CloudscaleMachineList) DeepCopyObject

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

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

type CloudscaleMachineSpec

type CloudscaleMachineSpec struct {
	// ProviderID is the unique identifier as specified by the cloud provider.
	// Format: cloudscale://<server-uuid>
	// +optional
	ProviderID *string `json:"providerID,omitempty"`

	// Flavor is the cloudscale.ch server flavor (e.g., "flex-8-4").
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength=1
	Flavor string `json:"flavor"`

	// Image is the OS image slug (e.g., "ubuntu-24.04"), custom image slug (e.g., "custom:ubuntu-foo"), or custom image UUID.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength=1
	Image string `json:"image"`

	// RootVolumeSize is the root volume size in GB.
	// +kubebuilder:validation:Minimum=10
	// +optional
	RootVolumeSize int `json:"rootVolumeSize,omitempty"`

	// Tags are key-value pairs to apply to the server.
	// +optional
	Tags map[string]string `json:"tags,omitempty"`

	// ServerGroup configures anti-affinity placement.
	// When specified, machines in the same server group are placed on different physical hosts.
	// N.B.: Only **up to 4 machines** can be placed in the same server group.
	// +optional
	ServerGroup *ServerGroupSpec `json:"serverGroup,omitempty"`
}

CloudscaleMachineSpec defines the desired state of CloudscaleMachine

func (*CloudscaleMachineSpec) DeepCopy

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

func (*CloudscaleMachineSpec) DeepCopyInto

func (in *CloudscaleMachineSpec) DeepCopyInto(out *CloudscaleMachineSpec)

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

type CloudscaleMachineStatus

type CloudscaleMachineStatus struct {
	// Initialization contains v1beta2 initialization tracking.
	// +optional
	Initialization *MachineInitializationStatus `json:"initialization,omitempty"`

	// ServerID is the cloudscale.ch server UUID.
	// +optional
	ServerID string `json:"serverID,omitempty"`

	// Addresses contains the machine's addresses.
	// +optional
	Addresses []clusterv1.MachineAddress `json:"addresses,omitempty"`

	// ServerGroupID is the cloudscale.ch server group UUID.
	// +optional
	ServerGroupID string `json:"serverGroupID,omitempty"`

	// conditions represent the current state of the CloudscaleMachine resource.
	// Each condition has a unique type and reflects the status of a specific aspect of the resource.
	//
	// Standard condition types include:
	// - "Available": the resource is fully functional
	// - "Progressing": the resource is being created or updated
	// - "Degraded": the resource failed to reach or maintain its desired state
	//
	// The status of each condition is one of True, False, or Unknown.
	// +listType=map
	// +listMapKey=type
	// +optional
	Conditions []metav1.Condition `json:"conditions,omitempty"`
}

CloudscaleMachineStatus defines the observed state of CloudscaleMachine.

func (*CloudscaleMachineStatus) DeepCopy

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

func (*CloudscaleMachineStatus) DeepCopyInto

func (in *CloudscaleMachineStatus) DeepCopyInto(out *CloudscaleMachineStatus)

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

type CloudscaleMachineTemplate

type CloudscaleMachineTemplate struct {
	metav1.TypeMeta `json:",inline"`

	// metadata is a standard object metadata
	// +optional
	metav1.ObjectMeta `json:"metadata,omitzero"`

	// spec defines the desired state of CloudscaleMachineTemplate
	// +required
	Spec CloudscaleMachineTemplateSpec `json:"spec"`

	// status defines the observed state of CloudscaleMachineTemplate
	// +optional
	Status CloudscaleMachineTemplateStatus `json:"status,omitzero"`
}

CloudscaleMachineTemplate is the Schema for the cloudscalemachinetemplates API

func (*CloudscaleMachineTemplate) DeepCopy

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

func (*CloudscaleMachineTemplate) DeepCopyInto

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

func (*CloudscaleMachineTemplate) DeepCopyObject

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

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

type CloudscaleMachineTemplateList

type CloudscaleMachineTemplateList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitzero"`
	Items           []CloudscaleMachineTemplate `json:"items"`
}

CloudscaleMachineTemplateList contains a list of CloudscaleMachineTemplate

func (*CloudscaleMachineTemplateList) DeepCopy

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

func (*CloudscaleMachineTemplateList) DeepCopyInto

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

func (*CloudscaleMachineTemplateList) DeepCopyObject

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

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

type CloudscaleMachineTemplateResource

type CloudscaleMachineTemplateResource struct {
	// Spec is the specification of the desired behavior of the machine.
	Spec CloudscaleMachineSpec `json:"spec"`
}

CloudscaleMachineTemplateResource describes the data needed to create a CloudscaleMachine from a template.

func (*CloudscaleMachineTemplateResource) DeepCopy

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

func (*CloudscaleMachineTemplateResource) DeepCopyInto

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

type CloudscaleMachineTemplateSpec

type CloudscaleMachineTemplateSpec struct {
	// Template contains the machine template specification.
	Template CloudscaleMachineTemplateResource `json:"template"`
}

CloudscaleMachineTemplateSpec defines the desired state of CloudscaleMachineTemplate.

func (*CloudscaleMachineTemplateSpec) DeepCopy

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

func (*CloudscaleMachineTemplateSpec) DeepCopyInto

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

type CloudscaleMachineTemplateStatus

type CloudscaleMachineTemplateStatus struct {
	// Capacity defines the resource capacity for nodes created from this template.
	// This value is used for autoscaling from zero operations as defined in:
	// https://github.com/kubernetes-sigs/cluster-api/blob/main/docs/proposals/20210310-opt-in-autoscaling-from-zero.md
	// +optional
	Capacity corev1.ResourceList `json:"capacity,omitempty"`

	// conditions represent the current state of the CloudscaleMachineTemplate resource.
	// Each condition has a unique type and reflects the status of a specific aspect of the resource.
	//
	// Standard condition types include:
	// - "Available": the resource is fully functional
	// - "Progressing": the resource is being created or updated
	// - "Degraded": the resource failed to reach or maintain its desired state
	//
	// The status of each condition is one of True, False, or Unknown.
	// +listType=map
	// +listMapKey=type
	// +optional
	Conditions []metav1.Condition `json:"conditions,omitempty"`
}

CloudscaleMachineTemplateStatus defines the observed state of CloudscaleMachineTemplate.

func (*CloudscaleMachineTemplateStatus) DeepCopy

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

func (*CloudscaleMachineTemplateStatus) DeepCopyInto

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

type ClusterInitializationStatus

type ClusterInitializationStatus struct {
	// Provisioned indicates that all cluster infrastructure has been provisioned.
	// True when Network, Subnet, Load Balancer, and Control Plane Endpoint are ready.
	// +optional
	Provisioned *bool `json:"provisioned,omitempty"`
}

ClusterInitializationStatus contains v1beta2 initialization tracking for CloudscaleCluster.

func (*ClusterInitializationStatus) DeepCopy

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

func (*ClusterInitializationStatus) DeepCopyInto

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

type HealthMonitorSpec

type HealthMonitorSpec struct {
	// DelayS is the interval between health checks in seconds.
	// +kubebuilder:default=5
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=300
	// +optional
	DelayS int `json:"delayS,omitempty"`

	// TimeoutS is the health check timeout in seconds.
	// +kubebuilder:default=3
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=300
	// +optional
	TimeoutS int `json:"timeoutS,omitempty"`

	// UpThreshold is the number of successful checks to mark healthy.
	// +kubebuilder:default=2
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=10
	// +optional
	UpThreshold int `json:"upThreshold,omitempty"`

	// DownThreshold is the number of failed checks to mark unhealthy.
	// +kubebuilder:default=3
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=10
	// +optional
	DownThreshold int `json:"downThreshold,omitempty"`
}

HealthMonitorSpec configures the load balancer health monitor.

func (*HealthMonitorSpec) DeepCopy

func (in *HealthMonitorSpec) DeepCopy() *HealthMonitorSpec

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

func (*HealthMonitorSpec) DeepCopyInto

func (in *HealthMonitorSpec) DeepCopyInto(out *HealthMonitorSpec)

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

type LoadBalancerSpec

type LoadBalancerSpec struct {
	// Enabled controls whether a load balancer is created for the control plane.
	// Set to false for external control planes (e.g., hosted control plane) where the endpoint
	// is provided externally.
	// +kubebuilder:default=true
	// +optional
	Enabled *bool `json:"enabled,omitempty"`

	// Algorithm is the load balancing algorithm.
	// +kubebuilder:validation:Enum=round_robin;least_connections;source_ip
	// +kubebuilder:default="round_robin"
	// +optional
	Algorithm string `json:"algorithm,omitempty"`

	// Flavor is the load balancer flavor (size).
	// +kubebuilder:default="lb-standard"
	// +optional
	Flavor string `json:"flavor,omitempty"`

	// APIServerPort is the port for the Kubernetes API server.
	// +kubebuilder:default=6443
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=65535
	// +optional
	APIServerPort int32 `json:"apiServerPort,omitempty"`

	// HealthMonitor configures the load balancer health monitor.
	// +optional
	HealthMonitor HealthMonitorSpec `json:"healthMonitor,omitempty"`
}

LoadBalancerSpec defines the load balancer configuration for the control plane.

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 MachineInitializationStatus

type MachineInitializationStatus struct {
	// Provisioned indicates that the machine infrastructure has been provisioned.
	// True when the server is running and ready.
	// +optional
	Provisioned *bool `json:"provisioned,omitempty"`
}

MachineInitializationStatus contains v1beta2 initialization tracking for CloudscaleMachine.

func (*MachineInitializationStatus) DeepCopy

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

func (*MachineInitializationStatus) DeepCopyInto

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

type NetworkSpec

type NetworkSpec struct {
	// CIDR is the CIDR block for the private network subnet.
	// +kubebuilder:default="10.0.0.0/24"
	// +optional
	CIDR string `json:"cidr,omitempty"`

	// GatewayAddress is the gateway IP address for the subnet.
	// By default, no gateway is configured on the private network subnet. This ensures
	// that outbound internet traffic uses the public network interface, which is required
	// for the Cloud Controller Manager to reach the cloudscale.ch API.
	// Set this to a specific IP address (e.g., "10.0.0.1") only if you have configured
	// a NAT gateway or similar infrastructure on the private network.
	// +optional
	GatewayAddress *string `json:"gatewayAddress,omitempty"`
}

NetworkSpec defines the network configuration.

func (*NetworkSpec) DeepCopy

func (in *NetworkSpec) DeepCopy() *NetworkSpec

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

func (*NetworkSpec) DeepCopyInto

func (in *NetworkSpec) DeepCopyInto(out *NetworkSpec)

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

type NodeInfo

type NodeInfo struct {
	// Architecture is the CPU architecture (e.g., "amd64", "arm64").
	// +optional
	Architecture string `json:"architecture,omitempty"`

	// OperatingSystem is the operating system (e.g., "linux").
	// +optional
	OperatingSystem string `json:"operatingSystem,omitempty"`
}

NodeInfo contains information about the node architecture and operating system.

func (*NodeInfo) DeepCopy

func (in *NodeInfo) DeepCopy() *NodeInfo

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

func (*NodeInfo) DeepCopyInto

func (in *NodeInfo) DeepCopyInto(out *NodeInfo)

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

type ResourceLifecycle

type ResourceLifecycle string

ResourceLifecycle configures the lifecycle of a resource.

type ServerGroupSpec

type ServerGroupSpec struct {
	// Name is the server group name. Machines with the same server group name
	// in the same zone will be placed on different physical hosts.
	// The server group is created automatically if it doesn't exist.
	// +kubebuilder:validation:Required
	// +kubebuilder:validation:MinLength=1
	Name string `json:"name"`
}

ServerGroupSpec configures server group placement for anti-affinity.

func (*ServerGroupSpec) DeepCopy

func (in *ServerGroupSpec) DeepCopy() *ServerGroupSpec

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

func (*ServerGroupSpec) DeepCopyInto

func (in *ServerGroupSpec) DeepCopyInto(out *ServerGroupSpec)

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