Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the infra.hkc.io v1alpha1 API group. +kubebuilder:object:generate=true +groupName=infra.hkc.io
Index ¶
- Variables
- type HCloudLoadBalancer
- type HCloudLoadBalancerList
- type HCloudLoadBalancerSpec
- type HCloudLoadBalancerStatus
- type HCloudNetwork
- type HCloudNetworkList
- type HCloudNetworkSpec
- type HCloudNetworkStatus
- type HCloudServer
- type HCloudServerList
- type HCloudServerSpec
- type HCloudServerStatus
- type HCloudVolume
- type HCloudVolumeList
- type HCloudVolumeSpec
- type HCloudVolumeStatus
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "infra.hkc.io", Version: "v1alpha1"} // 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 ¶
This section is empty.
Types ¶
type HCloudLoadBalancer ¶
type HCloudLoadBalancer struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec HCloudLoadBalancerSpec `json:"spec,omitempty"`
Status HCloudLoadBalancerStatus `json:"status,omitempty"`
}
HCloudLoadBalancer is the Schema for the hcloudloadbalancers API.
func (*HCloudLoadBalancer) DeepCopy ¶
func (in *HCloudLoadBalancer) DeepCopy() *HCloudLoadBalancer
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudLoadBalancer.
func (*HCloudLoadBalancer) DeepCopyInto ¶
func (in *HCloudLoadBalancer) DeepCopyInto(out *HCloudLoadBalancer)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudLoadBalancer) DeepCopyObject ¶
func (in *HCloudLoadBalancer) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudLoadBalancerList ¶
type HCloudLoadBalancerList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []HCloudLoadBalancer `json:"items"`
}
HCloudLoadBalancerList contains a list of HCloudLoadBalancer.
func (*HCloudLoadBalancerList) DeepCopy ¶
func (in *HCloudLoadBalancerList) DeepCopy() *HCloudLoadBalancerList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudLoadBalancerList.
func (*HCloudLoadBalancerList) DeepCopyInto ¶
func (in *HCloudLoadBalancerList) DeepCopyInto(out *HCloudLoadBalancerList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudLoadBalancerList) DeepCopyObject ¶
func (in *HCloudLoadBalancerList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudLoadBalancerSpec ¶
type HCloudLoadBalancerSpec struct {
// LoadBalancerType is the Hetzner load balancer type (e.g. lb11, lb21, lb31).
// +kubebuilder:validation:Required
// +kubebuilder:validation:MinLength=1
LoadBalancerType string `json:"loadBalancerType"`
// Location is the Hetzner datacenter location (e.g. fsn1, nbg1, hel1).
// +optional
Location string `json:"location,omitempty"`
// NetworkZone is the Hetzner network zone (e.g. eu-central, us-east).
// +optional
NetworkZone string `json:"networkZone,omitempty"`
// Algorithm selects the balancing algorithm. Supported values are
// "round_robin" and "least_connections".
// +optional
// +kubebuilder:default:=round_robin
// +kubebuilder:validation:Enum=round_robin;least_connections
Algorithm string `json:"algorithm,omitempty"`
// ServerSelector selects HCloudServer resources to attach as targets.
// This matches the Kubernetes labels on HCloudServer objects.
// +optional
ServerSelector *metav1.LabelSelector `json:"serverSelector,omitempty"`
// Labels to attach to the Hetzner Cloud load balancer resource.
// +optional
Labels map[string]string `json:"labels,omitempty"`
}
HCloudLoadBalancerSpec defines the desired state of an HCloudLoadBalancer. +kubebuilder:validation:XValidation:rule="!has(self.location) || !has(self.networkZone)",message="location and networkZone are mutually exclusive" +kubebuilder:validation:XValidation:rule="self.loadBalancerType == oldSelf.loadBalancerType",message="loadBalancerType is immutable after creation" +kubebuilder:validation:XValidation:rule="!has(oldSelf.location) || !has(self.location) || self.location == oldSelf.location",message="location is immutable after creation" +kubebuilder:validation:XValidation:rule="!has(oldSelf.networkZone) || !has(self.networkZone) || self.networkZone == oldSelf.networkZone",message="networkZone is immutable after creation"
func (*HCloudLoadBalancerSpec) DeepCopy ¶
func (in *HCloudLoadBalancerSpec) DeepCopy() *HCloudLoadBalancerSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudLoadBalancerSpec.
func (*HCloudLoadBalancerSpec) DeepCopyInto ¶
func (in *HCloudLoadBalancerSpec) DeepCopyInto(out *HCloudLoadBalancerSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HCloudLoadBalancerStatus ¶
type HCloudLoadBalancerStatus struct {
// LoadBalancerID is the Hetzner Cloud internal load balancer ID.
// +optional
LoadBalancerID int64 `json:"loadBalancerID,omitempty"`
// PublicIPv4 is the load balancer's public IPv4 address.
// +optional
PublicIPv4 string `json:"publicIPv4,omitempty"`
// PublicIPv6 is the load balancer's public IPv6 address.
// +optional
PublicIPv6 string `json:"publicIPv6,omitempty"`
// AttachedServerIDs are server IDs currently attached as targets.
// +optional
AttachedServerIDs []int64 `json:"attachedServerIDs,omitempty"`
// Conditions represent the latest available observations of the load balancer's current state.
// +optional
// +listType=map
// +listMapKey=type
Conditions []metav1.Condition `json:"conditions,omitempty"`
}
HCloudLoadBalancerStatus defines the observed state of an HCloudLoadBalancer.
func (*HCloudLoadBalancerStatus) DeepCopy ¶
func (in *HCloudLoadBalancerStatus) DeepCopy() *HCloudLoadBalancerStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudLoadBalancerStatus.
func (*HCloudLoadBalancerStatus) DeepCopyInto ¶
func (in *HCloudLoadBalancerStatus) DeepCopyInto(out *HCloudLoadBalancerStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HCloudNetwork ¶ added in v0.5.0
type HCloudNetwork struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec HCloudNetworkSpec `json:"spec,omitempty"`
Status HCloudNetworkStatus `json:"status,omitempty"`
}
HCloudNetwork is the Schema for the hcloudnetworks API. It represents a Hetzner Cloud private Network managed by the hcloud-operator.
func (*HCloudNetwork) DeepCopy ¶ added in v0.5.0
func (in *HCloudNetwork) DeepCopy() *HCloudNetwork
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudNetwork.
func (*HCloudNetwork) DeepCopyInto ¶ added in v0.5.0
func (in *HCloudNetwork) DeepCopyInto(out *HCloudNetwork)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudNetwork) DeepCopyObject ¶ added in v0.5.0
func (in *HCloudNetwork) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudNetworkList ¶ added in v0.5.0
type HCloudNetworkList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []HCloudNetwork `json:"items"`
}
HCloudNetworkList contains a list of HCloudNetwork.
func (*HCloudNetworkList) DeepCopy ¶ added in v0.5.0
func (in *HCloudNetworkList) DeepCopy() *HCloudNetworkList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudNetworkList.
func (*HCloudNetworkList) DeepCopyInto ¶ added in v0.5.0
func (in *HCloudNetworkList) DeepCopyInto(out *HCloudNetworkList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudNetworkList) DeepCopyObject ¶ added in v0.5.0
func (in *HCloudNetworkList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudNetworkSpec ¶ added in v0.5.0
type HCloudNetworkSpec struct {
// IPRange is the IPv4 CIDR for the private network (e.g. 10.0.0.0/16).
// +kubebuilder:validation:Required
// +kubebuilder:validation:MinLength=9
IPRange string `json:"ipRange"`
// NetworkZones lists Hetzner network zones where a Cloud subnet is created (e.g. eu-central, us-east, us-west).
// Subnets let you attach Cloud Servers in those zones to this network. Leave empty for a network with only the main IP range.
// +kubebuilder:validation:MaxItems=16
// +optional
NetworkZones []string `json:"networkZones,omitempty"`
// ExposeRoutesToVSwitch exposes routes to an attached vSwitch when applicable.
// +optional
ExposeRoutesToVSwitch bool `json:"exposeRoutesToVSwitch,omitempty"`
// Labels to attach to the Hetzner Cloud network resource.
// +optional
Labels map[string]string `json:"labels,omitempty"`
}
HCloudNetworkSpec defines the desired state of an HCloudNetwork. +kubebuilder:validation:XValidation:rule="self.ipRange == oldSelf.ipRange",message="ipRange is immutable after creation" +kubebuilder:validation:XValidation:rule="!has(oldSelf.networkZones) || self.networkZones == oldSelf.networkZones",message="networkZones is immutable after creation"
func (*HCloudNetworkSpec) DeepCopy ¶ added in v0.5.0
func (in *HCloudNetworkSpec) DeepCopy() *HCloudNetworkSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudNetworkSpec.
func (*HCloudNetworkSpec) DeepCopyInto ¶ added in v0.5.0
func (in *HCloudNetworkSpec) DeepCopyInto(out *HCloudNetworkSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HCloudNetworkStatus ¶ added in v0.5.0
type HCloudNetworkStatus struct {
// NetworkID is the Hetzner Cloud internal network ID.
// +optional
NetworkID int64 `json:"networkID,omitempty"`
// IPRange is the CIDR observed in Hetzner (echo of allocation).
// +optional
IPRange string `json:"ipRange,omitempty"`
// SubnetZones lists network zones where a Cloud subnet now exists on this network.
// +optional
SubnetZones []string `json:"subnetZones,omitempty"`
// Conditions represent the latest available observations of the network.
// +optional
// +listType=map
// +listMapKey=type
Conditions []metav1.Condition `json:"conditions,omitempty"`
}
HCloudNetworkStatus defines the observed state of an HCloudNetwork.
func (*HCloudNetworkStatus) DeepCopy ¶ added in v0.5.0
func (in *HCloudNetworkStatus) DeepCopy() *HCloudNetworkStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudNetworkStatus.
func (*HCloudNetworkStatus) DeepCopyInto ¶ added in v0.5.0
func (in *HCloudNetworkStatus) DeepCopyInto(out *HCloudNetworkStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HCloudServer ¶
type HCloudServer struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec HCloudServerSpec `json:"spec,omitempty"`
Status HCloudServerStatus `json:"status,omitempty"`
}
HCloudServer is the Schema for the hcloudservers API. It represents a Hetzner Cloud virtual machine managed by the hcloud-operator.
func (*HCloudServer) DeepCopy ¶
func (in *HCloudServer) DeepCopy() *HCloudServer
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudServer.
func (*HCloudServer) DeepCopyInto ¶
func (in *HCloudServer) DeepCopyInto(out *HCloudServer)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudServer) DeepCopyObject ¶
func (in *HCloudServer) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudServerList ¶
type HCloudServerList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []HCloudServer `json:"items"`
}
HCloudServerList contains a list of HCloudServer.
func (*HCloudServerList) DeepCopy ¶
func (in *HCloudServerList) DeepCopy() *HCloudServerList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudServerList.
func (*HCloudServerList) DeepCopyInto ¶
func (in *HCloudServerList) DeepCopyInto(out *HCloudServerList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudServerList) DeepCopyObject ¶
func (in *HCloudServerList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudServerSpec ¶
type HCloudServerSpec struct {
// ServerType is the Hetzner Cloud server type (e.g. cx21, cx31, cpx41).
// May be changed after creation; the controller powers off the server, changes type via the API, then powers it on again.
// +kubebuilder:validation:Required
// +kubebuilder:validation:MinLength=1
ServerType string `json:"serverType"`
// Image is the OS image to use (e.g. ubuntu-22.04, debian-12).
// +kubebuilder:validation:Required
// +kubebuilder:validation:MinLength=1
Image string `json:"image"`
// Location is the Hetzner datacenter location (e.g. fsn1, nbg1, hel1, ash, hil).
// +kubebuilder:validation:Required
// +kubebuilder:validation:MinLength=1
Location string `json:"location"`
// Labels to attach to the Hetzner Cloud server resource.
// +optional
Labels map[string]string `json:"labels,omitempty"`
// SSHKeys is a list of SSH key names or IDs to inject into the server on creation.
// +optional
SSHKeys []string `json:"sshKeys,omitempty"`
// UserData is cloud-init user-data to pass to the server on first boot.
// Must be a valid cloud-config or shell script. Applied once at creation time.
// +optional
// +kubebuilder:validation:MaxLength=32768
UserData string `json:"userData,omitempty"`
// NetworkRef points to an HCloudNetwork by name.
// When set, the controller attaches this server to the referenced private network.
// +optional
NetworkRef *corev1.LocalObjectReference `json:"networkRef,omitempty"`
}
HCloudServerSpec defines the desired state of an HCloudServer. +kubebuilder:validation:XValidation:rule="self.image == oldSelf.image",message="image is immutable after creation" +kubebuilder:validation:XValidation:rule="self.location == oldSelf.location",message="location is immutable after creation"
func (*HCloudServerSpec) DeepCopy ¶
func (in *HCloudServerSpec) DeepCopy() *HCloudServerSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudServerSpec.
func (*HCloudServerSpec) DeepCopyInto ¶
func (in *HCloudServerSpec) DeepCopyInto(out *HCloudServerSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HCloudServerStatus ¶
type HCloudServerStatus struct {
// ServerID is the Hetzner Cloud internal server ID.
// +optional
ServerID int64 `json:"serverID,omitempty"`
// State is the current Hetzner server state (e.g. running, stopped, initializing).
// +optional
State string `json:"state,omitempty"`
// AppliedServerType is the server type the controller has fully converged to (API type matches spec and server was running).
// While spec.serverType differs from the value in Hetzner, or before this field is set after a type change, a resize may be in progress.
// +optional
AppliedServerType string `json:"appliedServerType,omitempty"`
// PublicIPv4 is the server's public IPv4 address.
// +optional
PublicIPv4 string `json:"publicIPv4,omitempty"`
// PublicIPv6 is the server's public IPv6 network prefix.
// +optional
PublicIPv6 string `json:"publicIPv6,omitempty"`
// AppliedNetworkID is the network ID currently managed for this server via spec.networkRef.
// +optional
AppliedNetworkID int64 `json:"appliedNetworkID,omitempty"`
// Conditions represent the latest available observations of the server's current state.
// +optional
// +listType=map
// +listMapKey=type
Conditions []metav1.Condition `json:"conditions,omitempty"`
}
HCloudServerStatus defines the observed state of an HCloudServer.
func (*HCloudServerStatus) DeepCopy ¶
func (in *HCloudServerStatus) DeepCopy() *HCloudServerStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudServerStatus.
func (*HCloudServerStatus) DeepCopyInto ¶
func (in *HCloudServerStatus) DeepCopyInto(out *HCloudServerStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HCloudVolume ¶
type HCloudVolume struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec HCloudVolumeSpec `json:"spec,omitempty"`
Status HCloudVolumeStatus `json:"status,omitempty"`
}
HCloudVolume is the Schema for the hcloudvolumes API. It represents a Hetzner Cloud Volume managed by the hcloud-operator.
func (*HCloudVolume) DeepCopy ¶
func (in *HCloudVolume) DeepCopy() *HCloudVolume
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudVolume.
func (*HCloudVolume) DeepCopyInto ¶
func (in *HCloudVolume) DeepCopyInto(out *HCloudVolume)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudVolume) DeepCopyObject ¶
func (in *HCloudVolume) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudVolumeList ¶
type HCloudVolumeList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []HCloudVolume `json:"items"`
}
HCloudVolumeList contains a list of HCloudVolume.
func (*HCloudVolumeList) DeepCopy ¶
func (in *HCloudVolumeList) DeepCopy() *HCloudVolumeList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudVolumeList.
func (*HCloudVolumeList) DeepCopyInto ¶
func (in *HCloudVolumeList) DeepCopyInto(out *HCloudVolumeList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HCloudVolumeList) DeepCopyObject ¶
func (in *HCloudVolumeList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HCloudVolumeSpec ¶
type HCloudVolumeSpec struct {
// Size of the volume in GB (minimum 10, maximum 10240).
// +kubebuilder:validation:Required
Size int `json:"size"`
// Location of the volume (e.g. fsn1, nbg1, hel1).
// Required if ServerRef is not provided.
// +optional
Location string `json:"location,omitempty"`
// ServerRef is a reference to an HCloudServer in the same namespace to attach this volume to.
// +optional
ServerRef *corev1.LocalObjectReference `json:"serverRef,omitempty"`
// Format is the filesystem format to create on the volume (e.g., ext4, xfs).
// If empty, the volume is not formatted.
// +optional
Format string `json:"format,omitempty"`
// Labels to attach to the Hetzner Cloud volume.
// +optional
Labels map[string]string `json:"labels,omitempty"`
}
HCloudVolumeSpec defines the desired state of an HCloudVolume. +kubebuilder:validation:XValidation:rule="self.size >= 10 && self.size <= 10240",message="size must be between 10 and 10240 GB" +kubebuilder:validation:XValidation:rule="!has(oldSelf.location) || !has(self.location) || self.location == oldSelf.location",message="location is immutable after creation"
func (*HCloudVolumeSpec) DeepCopy ¶
func (in *HCloudVolumeSpec) DeepCopy() *HCloudVolumeSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudVolumeSpec.
func (*HCloudVolumeSpec) DeepCopyInto ¶
func (in *HCloudVolumeSpec) DeepCopyInto(out *HCloudVolumeSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HCloudVolumeStatus ¶
type HCloudVolumeStatus struct {
// VolumeID is the Hetzner Cloud internal volume ID.
// +optional
VolumeID int64 `json:"volumeID,omitempty"`
// State is the current Hetzner volume state (e.g. creating, available).
// +optional
State string `json:"state,omitempty"`
// AttachedServerID is the Hetzner Cloud server ID this volume is currently attached to.
// +optional
AttachedServerID int64 `json:"attachedServerID,omitempty"`
// LinuxDevice is the path to the device on the Linux server (e.g., /dev/disk/by-id/scsi-0HC_Volume_12345).
// +optional
LinuxDevice string `json:"linuxDevice,omitempty"`
// Conditions represent the latest available observations of the volume's current state.
// +optional
// +listType=map
// +listMapKey=type
Conditions []metav1.Condition `json:"conditions,omitempty"`
}
HCloudVolumeStatus defines the observed state of an HCloudVolume.
func (*HCloudVolumeStatus) DeepCopy ¶
func (in *HCloudVolumeStatus) DeepCopy() *HCloudVolumeStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HCloudVolumeStatus.
func (*HCloudVolumeStatus) DeepCopyInto ¶
func (in *HCloudVolumeStatus) DeepCopyInto(out *HCloudVolumeStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.