mirror of
https://github.com/shankar0123/certctl.git
synced 2026-06-07 12:21:31 +00:00
569aea255f
c70bb07 was incomplete. Replacing the YAML `#` comment block with a
Helm `{{- /* ... */ -}}` comment block was correct, but the NOTE
section I added explaining the syntax contained the literal
characters `*/ -}}` (it described the comment-syntax in prose).
Go templates DO NOT support nested comments. The lexer scans forward
from `{{- /*` looking for the FIRST `*/}}` or `*/ -}}` token and
treats whatever it finds as the comment terminator. So the literal
`*/ -}}` sequence inside my explanatory NOTE closed the comment
early, exposing the trailing narrative (which contained `{{ ... }}`
as descriptive text about template actions) as live YAML. Helm's
template engine then parsed `{{ ... }}` literal text as a real
template action whose body is `...` — `unexpected <.> in operand`
at servicemonitor.yaml:26.
Verified locally with helm 3.16.0 + the B3-helm-chart-coherence
ci-guard:
B3-helm-chart-coherence: clean (default + external-Postgres +
cert-manager + production hardening + 3 fail-fast gates +
DEPL-003 viaHook env render all green).
Fix: rewrote the NOTE without the literal closing-syntax `*/ -}}`
characters and without the `{{ ... }}` action-delimiter examples.
The narrative now points operators at docs/operator/helm-deployment.md
for the full explanation rather than inlining template-action examples
into the chart-template comment block.
Lesson update: descriptive references to Helm template actions inside
chart templates must live in Helm-comment blocks (correct) AND those
comment blocks must not contain the literal closing-delimiter sequence
`*/ -}}` as text (also correct). When in doubt, narrate the rule from
the operator-facing doc, don't inline syntax examples in chart-template
comments.