Skip to content

docs: list the env vars that disable insecure template functions and hooks - #2881

Merged
yxxhero merged 1 commit into
helmfile:mainfrom
lbarrosby:docs/fix-insecure-template-functions-env-var
Nov 9, 2026
Merged

yxxhero merged 1 commit into
helmfile:mainfrom
lbarrosby:docs/fix-insecure-template-functions-env-var

Conversation

@lbarrosby

Copy link
Copy Markdown
Contributor

The "Useful internal Helmfile environment variables" list in docs/templating.md documents HELMFILE_SKIP_INSECURE_TEMPLATE_FUNCTIONS, but nothing reads that name. The variable the code reads is HELMFILE_DISABLE_INSECURE_TEMPLATE_FUNCTIONS:

$ grep -rn "SKIP_INSECURE" --include='*.go' .
(no output)
$ grep -n "InsecureTemplateFunctions\|DisableHooks" pkg/envvar/const.go
5:	DisableInsecureTemplateFunctions = "HELMFILE_DISABLE_INSECURE_TEMPLATE_FUNCTIONS"
6:	DisableHooks                     = "HELMFILE_DISABLE_HOOKS"

pkg/tmpl/context_funcs.go uses it to make exec, envExec, readFile, readDir and readDirEntries return an error. The old name only appears in docs/proposals/towards-1.0.md, as the option to remove.

HELMFILE_DISABLE_HOOKS (pkg/event/bus.go: Trigger returns "HELMFILE_DISABLE_HOOKS is active, hooks are disabled" when a hook is configured) was not documented, so it is added to the same list.

Docs only; no code change.

…hooks

docs/templating.md documented HELMFILE_SKIP_INSECURE_TEMPLATE_FUNCTIONS,
which nothing reads. The code reads HELMFILE_DISABLE_INSECURE_TEMPLATE_FUNCTIONS
(pkg/envvar/const.go, pkg/tmpl/context_funcs.go). HELMFILE_DISABLE_HOOKS
(pkg/event/bus.go) was not documented at all.

Signed-off-by: Lucas Barros <[email protected]>
@yxxhero
yxxhero force-pushed the docs/fix-insecure-template-functions-env-var branch from 50570dd to 615b61d Compare November 8, 2026 12:41
@yxxhero
yxxhero merged commit 85666c3 into helmfile:main Nov 9, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants