Skip to content

Commit e8dfa9a

Browse files
committed
fix(helm): close validateSecret before the new shared-state define
The shared-state guard was added between validateSecret's inner {{ end }} and the one closing the define, so the new define nested inside it and the chart stopped parsing: 'unexpected <define> in command'. Neither the guard nor any other template rendered. Closes validateSecret first and drops the now-stray trailing end. Checked with helm lint plus template renders at one replica, at three without Redis (guard fires), and at three with Redis.
1 parent 0848f32 commit e8dfa9a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎charts/fcaptcha/templates/_helpers.tpl‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ to do by accident, and it costs one line of setup to satisfy.
6060
{{- if and (not .Values.secret) (not .Values.existingSecret) -}}
6161
{{- fail "\n\nfcaptcha: a token signing key is required.\n\n --set secret=$(openssl rand -hex 32)\n\nor point at one you already manage:\n\n --set existingSecret=my-fcaptcha-secret\n\nWithout it the server falls back to a key published in its own source, and\nanyone can mint tokens your backend will accept.\n" -}}
6262
{{- end -}}
63+
{{- end -}}
6364

6465
{{/* Multiple Go pods require shared security state. */}}
6566
{{- define "fcaptcha.validateSharedState" -}}
@@ -69,4 +70,3 @@ to do by accident, and it costs one line of setup to satisfy.
6970
{{- fail "\n\nfcaptcha: multiple replicas require Redis-backed shared state.\n\nSet redis.url or redis.existingSecret, or keep replicaCount=1 and autoscaling.enabled=false.\n" -}}
7071
{{- end -}}
7172
{{- end -}}
72-
{{- end -}}

0 commit comments

Comments
 (0)