rallly: default smtp.rejectUnauthorized to true

The deployment renders SMTP_REJECT_UNAUTHORIZED from
rallly.smtp.rejectUnauthorized, but values.yaml never carried the key. With
SMTP enabled the variable therefore reached the app as an empty string --
a certificate check nobody had configured either way.

It now defaults to true, so the mail server's certificate is verified unless
the operator switches the check off deliberately. values.yaml explains when
that is needed (a mail server with a self-signed certificate), because the
symptom otherwise points at the mail server rather than at this value.

The env var is not rendered with "| default true": an explicit false is a
zero value and default would swallow it, silently re-enabling the check the
operator just switched off. A nil falls back to true instead, so the variable
can no longer reach the app empty. The schema now rejects strings.

Operationally inert: the rallly fleet bundle and the deployed release both
have smtp.enabled: false, so the variable is not rendered at all -- the
render with SMTP disabled is byte-identical to before.

Major, because the runtime behaviour of mail sending changes.

Fixes #109
This commit is contained in:
jklein committed 2026-08-23 22:28:24 +02:00
1 parent d6de6de263
commit edb0837246
4 files changed
+20 -4

No files matched your search

+6 -1
View File
@@ -73,7 +73,12 @@ spec:
name: {{ .Release.Name }}-{{ .Chart.Name }}-smtp-secret
key: password
- name: SMTP_REJECT_UNAUTHORIZED
value: "{{ .Values.rallly.smtp.rejectUnauthorized }}"
{{- /* Not "| default true": an explicit false is a zero value, and
"default" would swallow it and silently re-enable the check
the operator just switched off. A nil (erased key) falls back
to the chart default true, so the variable can never reach
the app as an empty string (issues #109, #99). */}}
value: "{{ if kindIs "invalid" .Values.rallly.smtp.rejectUnauthorized }}true{{ else }}{{ .Values.rallly.smtp.rejectUnauthorized }}{{ end }}"
- name: SMTP_TLS_SERVERNAME
valueFrom:
secretKeyRef: