Skip to content

Intrinsic Functions

The Helm lexicon provides 23 intrinsic functions.

Tag? shows how an intrinsic is authored: a genuine tagged template (Sub\…`) or a plain function call (Ref(…)). **Folds?** shows whether [folding](/chant/concepts/typescript-as-data/#folded-vs-run) — the default chant build path — can reduce a use of this intrinsic today, without running the file — generated directly from this lexicon's registration, not restated by hand. A tagged template folds once it is registered. A plain call folds only where this lexicon has opted that intrinsic in one at a time (foldsAsCall), so a No` in this column means this intrinsic has not been opted in, not that calls in general cannot fold.

FunctionDescriptionOutput KeyTag?Folds?
valuesProxy accessor for {{ .Values.x }} referencesvaluesNoNo
ReleaseBuilt-in Release object (Name, Namespace, etc.)ReleaseNoNo
ChartRefBuilt-in Chart object (Name, Version, AppVersion)ChartRefNoNo
includeInclude a named template: {{ include “name” . }}includeNoYes
requiredRequire a value: {{ required “msg” .Values.x }}requiredNoYes
helmDefaultDefault value: {{ default “def” .Values.x }}helmDefaultNoYes
toYamlConvert to YAML: {{ toYaml .Values.xnindent N }}toYamlNo
quoteQuote a value: {{ .Values.xquote }}quoteNo
printfFormat string: {{ printf “%s” .Values.x }}printfNoYes
tplEvaluate template: {{ tpl .Values.x . }}tplNoYes
lookupLookup resource: {{ lookup “v1” “Secret” “ns” “name” }}lookupNoYes
CapabilitiesBuilt-in Capabilities object (KubeVersion, APIVersions, HelmVersion)CapabilitiesNoNo
TemplateBuilt-in Template object (Name, BasePath)TemplateNoNo
filesGet.Files.Get: {{ .Files.Get “path” }}filesGetNoYes
filesGlob.Files.Glob: {{ .Files.Glob “pattern” }}filesGlobNoYes
filesAsConfig.Files.Glob.AsConfig for ConfigMap datafilesAsConfigNoYes
filesAsSecrets.Files.Glob.AsSecrets for Secret datafilesAsSecretsNoYes
ElseIfElse-if chaining: {{- else if .Values.x }}…{{- end }}ElseIfNoNo
IfConditional: {{- if .Values.x }}…{{- end }}IfNoNo
RangeRange loop: {{- range .Values.x }}…{{- end }}RangeNoNo
WithWith scope: {{- with .Values.x }}…{{- end }}WithNoNo
withOrderHelm hook annotations for resource ordering (pre-install/pre-upgrade)withOrderNoNo
argoWaveArgo CD sync wave annotationargoWaveNoNo