Skip to content

Commit 7f6ca6f

Browse files
syn2mas job: enhance synapse & mas context usage
1 parent dde8ea9 commit 7f6ca6f

File tree

1 file changed

+8
-12
lines changed

1 file changed

+8
-12
lines changed

charts/matrix-stack/templates/matrix-authentication-service/syn2mas_job.yaml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -122,10 +122,10 @@ spec:
122122
{{- toYaml . | nindent 10 }}
123123
{{- end }}
124124
command:
125-
{{- include "element-io.matrix-authentication-service.render-config" (dict "root" $ "context" .) | nindent 8 }}
125+
{{- include "element-io.matrix-authentication-service.render-config" (dict "root" $ "context" $masContext) | nindent 8 }}
126126
env:
127-
{{- include "element-io.matrix-authentication-service.matrixToolsEnv" (dict "root" $ "context" .) | nindent 8 }}
128-
{{- include "element-io.matrix-authentication-service.env" (dict "root" $ "context" .) | nindent 8 }}
127+
{{- include "element-io.matrix-authentication-service.matrixToolsEnv" (dict "root" $ "context" $masContext) | nindent 8 }}
128+
{{- include "element-io.matrix-authentication-service.env" (dict "root" $ "context" $masContext) | nindent 8 }}
129129
{{- with .extraEnv }}
130130
{{- toYaml . | nindent 8 }}
131131
{{- end }}
@@ -145,7 +145,6 @@ spec:
145145
- mountPath: /conf
146146
name: rendered-config
147147
readOnly: false
148-
{{- with $synapseContext }}
149148
- name: render-config-syn
150149
{{- with $.Values.matrixTools.image -}}
151150
{{- if .digest }}
@@ -161,10 +160,10 @@ spec:
161160
{{- toYaml . | nindent 10 }}
162161
{{- end }}
163162
command:
164-
{{- include "element-io.synapse.render-config" (dict "root" $ "context" .) | nindent 8 }}
163+
{{- include "element-io.synapse.render-config" (dict "root" $ "context" $synapseContext) | nindent 8 }}
165164
env:
166-
{{- include "element-io.synapse.matrixToolsEnv" (dict "root" $ "context" .) | nindent 8 }}
167-
{{- include "element-io.synapse.env" (dict "root" $ "context" .) | nindent 8 }}
165+
{{- include "element-io.synapse.matrixToolsEnv" (dict "root" $ "context" $synapseContext) | nindent 8 }}
166+
{{- include "element-io.synapse.env" (dict "root" $ "context" $synapseContext) | nindent 8 }}
168167
{{- with .extraEnv }}
169168
{{- toYaml . | nindent 8 }}
170169
{{- end }}
@@ -184,7 +183,6 @@ spec:
184183
- mountPath: /conf
185184
name: rendered-config
186185
readOnly: false
187-
{{- end }}
188186
- name: db-wait-mas
189187
{{- with $.Values.matrixTools.image -}}
190188
{{- if .digest }}
@@ -203,12 +201,11 @@ spec:
203201
- "/matrix-tools"
204202
- tcpwait
205203
- -address
206-
- {{ include "element-io.ess-library.postgres-host-port" (dict "root" $ "context" (dict "postgres" .postgres)) | quote }}
204+
- {{ include "element-io.ess-library.postgres-host-port" (dict "root" $ "context" (dict "postgres" $masContext.postgres)) | quote }}
207205
{{- with .resources }}
208206
resources:
209207
{{- toYaml . | nindent 10 }}
210208
{{- end }}
211-
{{- with $synapseContext }}
212209
- name: db-wait-syn
213210
{{- with $.Values.matrixTools.image -}}
214211
{{- if .digest }}
@@ -227,11 +224,10 @@ spec:
227224
- "/matrix-tools"
228225
- tcpwait
229226
- -address
230-
- {{ include "element-io.ess-library.postgres-host-port" (dict "root" $ "context" (dict "postgres" .postgres)) | quote }}
227+
- {{ include "element-io.ess-library.postgres-host-port" (dict "root" $ "context" (dict "postgres" $synapseContext.postgres)) | quote }}
231228
{{- with .resources }}
232229
resources:
233230
{{- toYaml . | nindent 10 }}
234-
{{- end }}
235231
{{- end }}
236232
- name: syn2mas-check
237233
args: ["syn2mas", "check", "--config", "/conf/config.yaml", "--synapse-config", "/conf/homeserver.yaml"]

0 commit comments

Comments
 (0)