Skip to content

Commit fbf1426

Browse files
committed
add affinity to CP and Ingress PODs
1 parent db4f9b0 commit fbf1426

File tree

4 files changed

+16
-0
lines changed

4 files changed

+16
-0
lines changed

deployments/charts/kuma/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ A Helm chart for the Kuma Control Plane
2525
| controlPlane.autoscaling.targetCPUUtilizationPercentage | int | `80` | For clusters that don't support autoscaling/v2beta, autoscaling/v1 is used |
2626
| controlPlane.autoscaling.metrics | list | `[{"resource":{"name":"cpu","target":{"averageUtilization":80,"type":"Utilization"}},"type":"Resource"}]` | For clusters that do support autoscaling/v2beta, use metrics |
2727
| controlPlane.nodeSelector | object | `{"kubernetes.io/arch":"amd64","kubernetes.io/os":"linux"}` | Node selector for the Kuma Control Plane pods |
28+
| controlPlane.affinity | object | `{}` | Affinity placement rule for the Kuma Control Plane pods |
2829
| controlPlane.injectorFailurePolicy | string | `"Ignore"` | Failure policy of the mutating webhook implemented by the Kuma Injector component |
2930
| controlPlane.service.name | string | `nil` | Optionally override of the Kuma Control Plane Service's name |
3031
| controlPlane.service.type | string | `"ClusterIP"` | Service type of the Kuma Control Plane |
@@ -70,6 +71,7 @@ A Helm chart for the Kuma Control Plane
7071
| ingress.service.port | int | `10001` | Port on which Ingress is exposed |
7172
| ingress.annotations | object | `{}` | Additional deployment annotation |
7273
| ingress.nodeSelector | object | `{"kubernetes.io/arch":"amd64","kubernetes.io/os":"linux"}` | Node Selector for the Ingress pods |
74+
| ingress.affinity | object | `{}` | Affinity placement rule for the Kuma Ingress pods |
7375
| kumactl.image.repository | string | `"kumactl"` | The kumactl image repository |
7476
| kubectl.image.registry | string | `"bitnami"` | The kubectl image registry |
7577
| kubectl.image.repository | string | `"kubectl"` | The kubectl image repository |

deployments/charts/kuma/templates/cp-deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ spec:
2525
{{- include "kuma.selectorLabels" . | nindent 8 }}
2626
app: {{ include "kuma.name" . }}-control-plane
2727
spec:
28+
{{- with .Values.controlPlane.affinity }}
29+
affinity:
30+
{{ toYaml . | nindent 8 }}
31+
{{- end }}
2832
serviceAccountName: {{ include "kuma.name" . }}-control-plane
2933
{{- with .Values.controlPlane.nodeSelector }}
3034
nodeSelector:

deployments/charts/kuma/templates/ingress-deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ spec:
3030
{{- include "kuma.selectorLabels" . | nindent 8 }}
3131
app: kuma-ingress
3232
spec:
33+
{{- with .Values.ingress.affinity }}
34+
affinity:
35+
{{ toYaml . | nindent 8 }}
36+
{{- end }}
3337
serviceAccountName: {{ include "kuma.name" . }}-ingress
3438
{{- with .Values.ingress.nodeSelector }}
3539
nodeSelector:

deployments/charts/kuma/values.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,9 @@ controlPlane:
5656
kubernetes.io/os: linux
5757
kubernetes.io/arch: amd64
5858

59+
# -- Affinity placement rule for the Kuma Control Plane pods
60+
affinity: {}
61+
5962
# -- Failure policy of the mutating webhook implemented by the Kuma Injector component
6063
injectorFailurePolicy: Ignore
6164

@@ -192,6 +195,9 @@ ingress:
192195
nodeSelector:
193196
kubernetes.io/os: linux
194197
kubernetes.io/arch: amd64
198+
199+
# -- Affinity placement rule for the Kuma Ingress pods
200+
affinity: {}
195201

196202
kumactl:
197203
image:

0 commit comments

Comments
 (0)