Skip to content
This repository was archived by the owner on Nov 25, 2024. It is now read-only.

Commit 07e59d0

Browse files
authored
Helm Chart - Add configuration for node selector / tolerations / affi… (#3433)
For some experimentation I'm doing, I need to pin Dendrite to a specific node pool. This should be available configuration within the chart ideally, and this should do it in theory. ### Pull Request Checklist <!-- Please read https://matrix-org.github.io/dendrite/development/contributing before submitting your pull request --> * [x] I have added Go unit tests or [Complement integration tests](https://github.com/matrix-org/complement) for this PR _or_ I have justified why this PR doesn't need tests * [x] Pull request includes a [sign off below using a legally identifiable name](https://matrix-org.github.io/dendrite/development/contributing#sign-off) _or_ I have already signed off privately Signed-off-by: `Rhea Danzey <rdanzey@element.io>` --------- Signed-off-by: Rhea Danzey <rdanzey@element.io>
1 parent c914f06 commit 07e59d0

File tree

4 files changed

+40
-1
lines changed

4 files changed

+40
-1
lines changed

helm/dendrite/Chart.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
apiVersion: v2
22
name: dendrite
3-
version: "0.14.5"
3+
version: "0.14.6"
44
appVersion: "0.13.8"
55
description: Dendrite Matrix Homeserver
66
type: application

helm/dendrite/templates/deployment.yaml

+15
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,9 @@ spec:
5656
args:
5757
- '--config'
5858
- '/etc/dendrite/dendrite.yaml'
59+
{{- with .Values.extraArgs }}
60+
{{- toYaml . | nindent 10 }}
61+
{{- end }}
5962
ports:
6063
- name: http
6164
containerPort: 8008
@@ -113,4 +116,16 @@ spec:
113116
imagePullSecrets:
114117
{{- with .Values.imagePullSecrets }}
115118
{{ . | toYaml | nindent 6 }}
119+
{{- end }}
120+
{{- with .Values.nodeSelector }}
121+
nodeSelector:
122+
{{- toYaml . | nindent 8 }}
123+
{{- end }}
124+
{{- with .Values.affinity }}
125+
affinity:
126+
{{- toYaml . | nindent 8 }}
127+
{{- end }}
128+
{{- with .Values.tolerations }}
129+
tolerations:
130+
{{- toYaml . | nindent 8 }}
116131
{{- end }}

helm/dendrite/templates/jobs.yaml

+12
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,18 @@ spec:
9898
volumes:
9999
- name: signing-key
100100
emptyDir: {}
101+
{{- with .Values.nodeSelector }}
102+
nodeSelector:
103+
{{- toYaml . | nindent 8 }}
104+
{{- end }}
105+
{{- with .Values.affinity }}
106+
affinity:
107+
{{- toYaml . | nindent 8 }}
108+
{{- end }}
109+
{{- with .Values.tolerations }}
110+
tolerations:
111+
{{- toYaml . | nindent 8 }}
112+
{{- end }}
101113
parallelism: 1
102114
completions: 1
103115
backoffLimit: 1

helm/dendrite/values.yaml

+12
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ persistence:
7777
# GKE, AWS & OpenStack)
7878
storageClass:
7979

80+
# -- Add additional arguments to the dendrite command
81+
extraArgs: []
82+
8083
# -- Add additional volumes to the Dendrite Pod
8184
extraVolumes: []
8285
# ex.
@@ -100,6 +103,15 @@ strategy:
100103
# -- Maximum number of pods that can be scheduled above the desired number of pods
101104
maxSurge: 25%
102105

106+
# -- Node selector configuration
107+
nodeSelector: {}
108+
109+
# -- Tolerations configuration
110+
tolerations: {}
111+
112+
# -- Affinity configuration
113+
affinity: {}
114+
103115
dendrite_config:
104116
version: 2
105117
global:

0 commit comments

Comments
 (0)