mirror of
https://github.com/truenas/charts.git
synced 2026-06-18 09:37:12 +08:00
add comments
This commit is contained in:
@@ -1,3 +1,13 @@
|
||||
{{/*
|
||||
Call this template like this;
|
||||
{{- include "ix.v1.common.class.configmap" (dict "root" $root "values" $values) -}}
|
||||
$values contains:
|
||||
name: string
|
||||
labels: dict
|
||||
annotations: dict
|
||||
contentType: yaml (only supported type)
|
||||
data: (data | toYaml)
|
||||
*/}}
|
||||
{{- define "ix.v1.common.class.configmap" -}}
|
||||
{{- $values := .values -}}
|
||||
{{- $root := .root }}
|
||||
|
||||
@@ -1,3 +1,14 @@
|
||||
{{/*
|
||||
Call this template like this;
|
||||
{{- include "ix.v1.common.class.configmap" (dict "root" $root "values" $values) -}}
|
||||
$values contains:
|
||||
name: string
|
||||
labels: dict
|
||||
annotations: dict
|
||||
contentType: yaml | certificate | pullSecret
|
||||
data: dict or (data | toYaml) when contentType is yaml
|
||||
secretType: custom secret type (optional)
|
||||
*/}}
|
||||
{{- define "ix.v1.common.class.secret" -}}
|
||||
{{- $values := .values -}}
|
||||
{{- $root := .root -}}
|
||||
@@ -41,6 +52,6 @@ data:
|
||||
stringData:
|
||||
{{- $values.data | nindent 2 }}
|
||||
{{- else -}}
|
||||
{{- fail (printf "Invalid content type (%s) for secret. Valid types are pullSecret, certificate, scalar and key_value" $values.contentType) -}}
|
||||
{{- fail (printf "Invalid content type (%s) for secret. Valid types are pullSecret, certificate, yaml" $values.contentType) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
Reference in New Issue
Block a user