helmzoo/helmule/examples/extensions/flux2/crd-configmap.yaml
Nikolai Rodionov aabcb21f3b
Helmule MVP
Basic functionality is there, helmule can mirror helm chart with small
modifications
2024-02-11 08:29:22 +01:00

29 lines
888 B
YAML

{{/*
We have to create individual configmaps for each CRD - they exceed the total
allowed length for a configmap if they are combined.
*/}}
{{ $currentScope := . }}
{{- if .Values.crds.install }}
{{- range $path, $_ := .Files.Glob "crd-base/**" }}
{{- with $currentScope }}
---
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "crdInstall" . }}-{{ $path | base | trimSuffix ".yaml" }}
namespace: {{ .Release.Namespace | quote }}
annotations:
# create hook dependencies in the right order
"helm.sh/hook-weight": "-5"
{{- include "crdInstallAnnotations" . | nindent 4 }}
labels:
app.kubernetes.io/component: {{ include "crdInstall" . | quote }}
{{- include "labels.selector" . | nindent 4 }}
role: {{ include "crdInstallSelector" . | quote }}
data:
content: |
{{ tpl (.Files.Get $path) . | indent 4 }}
{{- end }}
{{- end }}
{{- end }}