diff --git a/api/k0smotron.io/v1beta1/k0smotroncluster_types.go b/api/k0smotron.io/v1beta1/k0smotroncluster_types.go
index 1e9b83f24..dee636b96 100644
--- a/api/k0smotron.io/v1beta1/k0smotroncluster_types.go
+++ b/api/k0smotron.io/v1beta1/k0smotroncluster_types.go
@@ -175,6 +175,12 @@ type ServiceSpec struct {
// Annotations defines extra annotations to be added to the service.
//+kubebuilder:validation:Optional
Annotations map[string]string `json:"annotations,omitempty"`
+ // Labels defines extra labels to be added to the service.
+ //+kubebuilder:validation:Optional
+ Labels map[string]string `json:"labels,omitempty"`
+ // LoadBalancerClass defines the load balancer class to be used for the service. Used only when service type is LoadBalancer.
+ //+kubebuilder:validation:Optional
+ LoadBalancerClass *string `json:"loadBalancerClass,omitempty"`
}
//+kubebuilder:object:root=true
diff --git a/api/k0smotron.io/v1beta1/zz_generated.deepcopy.go b/api/k0smotron.io/v1beta1/zz_generated.deepcopy.go
index 9034831f2..b23934710 100644
--- a/api/k0smotron.io/v1beta1/zz_generated.deepcopy.go
+++ b/api/k0smotron.io/v1beta1/zz_generated.deepcopy.go
@@ -434,6 +434,18 @@ func (in *ServiceSpec) DeepCopyInto(out *ServiceSpec) {
(*out)[key] = val
}
}
+ if in.Labels != nil {
+ in, out := &in.Labels, &out.Labels
+ *out = make(map[string]string, len(*in))
+ for key, val := range *in {
+ (*out)[key] = val
+ }
+ }
+ if in.LoadBalancerClass != nil {
+ in, out := &in.LoadBalancerClass, &out.LoadBalancerClass
+ *out = new(string)
+ **out = **in
+ }
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServiceSpec.
diff --git a/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml b/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml
index 9541b905c..5bfc9bdd2 100644
--- a/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml
+++ b/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml
@@ -3942,6 +3942,15 @@ spec:
KonnectivityPort defines the konnectivity port. If empty k0smotron
will pick it automatically.
type: integer
+ labels:
+ additionalProperties:
+ type: string
+ description: Labels defines extra labels to be added to the service.
+ type: object
+ loadBalancerClass:
+ description: LoadBalancerClass defines the load balancer class
+ to be used for the service. Used only when service type is LoadBalancer.
+ type: string
type:
default: ClusterIP
description: Service Type string describes ingress methods for
diff --git a/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml b/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml
index 7b56a1dea..9d741f374 100644
--- a/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml
+++ b/config/clusterapi/controlplane/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml
@@ -4020,6 +4020,17 @@ spec:
KonnectivityPort defines the konnectivity port. If empty k0smotron
will pick it automatically.
type: integer
+ labels:
+ additionalProperties:
+ type: string
+ description: Labels defines extra labels to be added to
+ the service.
+ type: object
+ loadBalancerClass:
+ description: LoadBalancerClass defines the load balancer
+ class to be used for the service. Used only when service
+ type is LoadBalancer.
+ type: string
type:
default: ClusterIP
description: Service Type string describes ingress methods
diff --git a/config/clusterapi/k0smotron.io/bases/k0smotron.io_clusters.yaml b/config/clusterapi/k0smotron.io/bases/k0smotron.io_clusters.yaml
index c6734e459..41a61b881 100644
--- a/config/clusterapi/k0smotron.io/bases/k0smotron.io_clusters.yaml
+++ b/config/clusterapi/k0smotron.io/bases/k0smotron.io_clusters.yaml
@@ -3945,6 +3945,15 @@ spec:
KonnectivityPort defines the konnectivity port. If empty k0smotron
will pick it automatically.
type: integer
+ labels:
+ additionalProperties:
+ type: string
+ description: Labels defines extra labels to be added to the service.
+ type: object
+ loadBalancerClass:
+ description: LoadBalancerClass defines the load balancer class
+ to be used for the service. Used only when service type is LoadBalancer.
+ type: string
type:
default: ClusterIP
description: Service Type string describes ingress methods for
diff --git a/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml b/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml
index 9541b905c..5bfc9bdd2 100644
--- a/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml
+++ b/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanes.yaml
@@ -3942,6 +3942,15 @@ spec:
KonnectivityPort defines the konnectivity port. If empty k0smotron
will pick it automatically.
type: integer
+ labels:
+ additionalProperties:
+ type: string
+ description: Labels defines extra labels to be added to the service.
+ type: object
+ loadBalancerClass:
+ description: LoadBalancerClass defines the load balancer class
+ to be used for the service. Used only when service type is LoadBalancer.
+ type: string
type:
default: ClusterIP
description: Service Type string describes ingress methods for
diff --git a/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml b/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml
index 7b56a1dea..9d741f374 100644
--- a/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml
+++ b/config/crd/bases/controlplane.cluster.x-k8s.io_k0smotroncontrolplanetemplates.yaml
@@ -4020,6 +4020,17 @@ spec:
KonnectivityPort defines the konnectivity port. If empty k0smotron
will pick it automatically.
type: integer
+ labels:
+ additionalProperties:
+ type: string
+ description: Labels defines extra labels to be added to
+ the service.
+ type: object
+ loadBalancerClass:
+ description: LoadBalancerClass defines the load balancer
+ class to be used for the service. Used only when service
+ type is LoadBalancer.
+ type: string
type:
default: ClusterIP
description: Service Type string describes ingress methods
diff --git a/config/crd/bases/k0smotron.io_clusters.yaml b/config/crd/bases/k0smotron.io_clusters.yaml
index c6734e459..41a61b881 100644
--- a/config/crd/bases/k0smotron.io_clusters.yaml
+++ b/config/crd/bases/k0smotron.io_clusters.yaml
@@ -3945,6 +3945,15 @@ spec:
KonnectivityPort defines the konnectivity port. If empty k0smotron
will pick it automatically.
type: integer
+ labels:
+ additionalProperties:
+ type: string
+ description: Labels defines extra labels to be added to the service.
+ type: object
+ loadBalancerClass:
+ description: LoadBalancerClass defines the load balancer class
+ to be used for the service. Used only when service type is LoadBalancer.
+ type: string
type:
default: ClusterIP
description: Service Type string describes ingress methods for
diff --git a/docs/resource-reference.md b/docs/resource-reference.md
index ef0ff2eae..76305942d 100644
--- a/docs/resource-reference.md
+++ b/docs/resource-reference.md
@@ -10949,6 +10949,20 @@ will pick it automatically.
Default: 30132