Skip to content

Commit 19efcbf

Browse files
authored
Merge pull request #9 from /issues/5
feat: scheduler constraints for tcp pods
2 parents aa45a20 + db99c00 commit 19efcbf

File tree

3 files changed

+62
-1
lines changed

3 files changed

+62
-1
lines changed

charts/capi-kamaji-proxmox/README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,13 @@ A Helm chart for deploying a Kamaji Tenant Cluster on Proxmox VE using Cluster A
2525
| cluster.controlPlane.addons.konnectivity | object | `{}` | KamajiControlPlane konnectivity configuration |
2626
| cluster.controlPlane.addons.kubeProxy | object | `{}` | KamajiControlPlane kube-proxy configuration |
2727
| cluster.controlPlane.dataStoreName | string | `"default"` | KamajiControlPlane dataStoreName |
28+
| cluster.controlPlane.deployment | object | `{"additionalMetadata":{"annotations":{},"labels":{}},"affinity":{},"nodeSelector":{"kubernetes.io/os":"linux"},"podAdditionalMetadata":{"annotations":{},"labels":{}},"tolerations":[],"topologySpreadConstraints":[]}` | Configure how KamajiControlPlane deployment should be done |
29+
| cluster.controlPlane.deployment.additionalMetadata | object | `{"annotations":{},"labels":{}}` | Additional metadata as labels and annotations |
30+
| cluster.controlPlane.deployment.affinity | object | `{}` | Affinity scheduling rules |
31+
| cluster.controlPlane.deployment.nodeSelector | object | `{"kubernetes.io/os":"linux"}` | NodeSelector for scheduling |
32+
| cluster.controlPlane.deployment.podAdditionalMetadata | object | `{"annotations":{},"labels":{}}` | Pods Additional metadata as labels and annotations |
33+
| cluster.controlPlane.deployment.tolerations | list | `[]` | Tolerations for scheduling |
34+
| cluster.controlPlane.deployment.topologySpreadConstraints | list | `[]` | TopologySpreadConstraints for scheduling |
2835
| cluster.controlPlane.kubelet.cgroupfs | string | `"systemd"` | kubelet cgroupfs configuration |
2936
| cluster.controlPlane.kubelet.preferredAddressTypes | list | `["InternalIP","ExternalIP","Hostname"]` | kubelet preferredAddressTypes order |
3037
| cluster.controlPlane.labels | object | `{"cni":"calico"}` | Labels to add to the control plane |

charts/capi-kamaji-proxmox/templates/kamaji-control-plane.yaml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,41 @@ spec:
1414
coreDNS: {}
1515
kubeProxy: {}
1616
konnectivity: {}
17+
deployment:
18+
additionalMetadata:
19+
labels:
20+
{{- with .Values.cluster.controlPlane.deployment.additionalMetadata.labels }}
21+
{{- toYaml . | nindent 8 }}
22+
{{- end }}
23+
annotations:
24+
{{- with .Values.cluster.controlPlane.deployment.additionalMetadata.annotations }}
25+
{{- toYaml . | nindent 8 }}
26+
{{- end }}
27+
podAdditionalMetadata:
28+
labels:
29+
{{- with .Values.cluster.controlPlane.deployment.podAdditionalMetadata.labels }}
30+
{{- toYaml . | nindent 8 }}
31+
{{- end }}
32+
annotations:
33+
{{- with .Values.cluster.controlPlane.deployment.podAdditionalMetadata.annotations }}
34+
{{- toYaml . | nindent 8 }}
35+
{{- end }}
36+
affinity:
37+
{{- with .Values.cluster.controlPlane.deployment.affinity }}
38+
{{- toYaml . | nindent 6 }}
39+
{{- end }}
40+
tolerations:
41+
{{- with .Values.cluster.controlPlane.deployment.tolerations }}
42+
{{- toYaml . | nindent 6 }}
43+
{{- end }}
44+
nodeSelector:
45+
{{- with .Values.cluster.controlPlane.deployment.nodeSelector }}
46+
{{- toYaml . | nindent 6 }}
47+
{{- end }}
48+
topologySpreadConstraints:
49+
{{- with .Values.cluster.controlPlane.deployment.topologySpreadConstraints }}
50+
{{- toYaml . | nindent 6 }}
51+
{{- end }}
1752
kubelet:
1853
cgroupfs: {{ .Values.cluster.controlPlane.kubelet.cgroupfs | quote }}
1954
preferredAddressTypes:

charts/capi-kamaji-proxmox/values.yaml

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,25 @@ cluster:
3535
kubeProxy: {}
3636
# -- KamajiControlPlane konnectivity configuration
3737
konnectivity: {}
38+
# -- Configure how KamajiControlPlane deployment should be done
39+
deployment:
40+
# -- Additional metadata as labels and annotations
41+
additionalMetadata:
42+
labels: {}
43+
annotations: {}
44+
# -- Pods Additional metadata as labels and annotations
45+
podAdditionalMetadata:
46+
labels: {}
47+
annotations: {}
48+
# -- Affinity scheduling rules
49+
affinity: {}
50+
# -- Tolerations for scheduling
51+
tolerations: []
52+
# -- NodeSelector for scheduling
53+
nodeSelector:
54+
kubernetes.io/os: linux
55+
# -- TopologySpreadConstraints for scheduling
56+
topologySpreadConstraints: []
3857
kubelet:
3958
# -- kubelet cgroupfs configuration
4059
cgroupfs: systemd
@@ -52,7 +71,7 @@ cluster:
5271
# serviceAddress: "10.10.10.120"
5372
# When using MetalLB to expose the Control Plane, set as the following to specify a specific IP address for the service
5473
# serviceAnnotations:
55-
# metallb.universe.tf/loadBalancerIPs: "10.10.10.120"
74+
# metallb.io/loadBalancerIPs: "10.10.10.120"
5675
# -- Labels to use for the control plane service
5776
serviceLabels: {}
5877
# -- List of additional Subject Alternative Names to use for the API Server serving certificate

0 commit comments

Comments
 (0)