diff --git a/library/common/1.0.0/templates/class/_configmap.tpl b/library/common/1.0.0/templates/class/_configmap.tpl index c1ba181113..1673fe7142 100644 --- a/library/common/1.0.0/templates/class/_configmap.tpl +++ b/library/common/1.0.0/templates/class/_configmap.tpl @@ -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 }} diff --git a/library/common/1.0.0/templates/class/_secret.tpl b/library/common/1.0.0/templates/class/_secret.tpl index 0dcc792035..d91d6f9a85 100644 --- a/library/common/1.0.0/templates/class/_secret.tpl +++ b/library/common/1.0.0/templates/class/_secret.tpl @@ -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 -}}