'How i can read a yaml dict and use it inside helm-template
I am creating a helm libary that i will use in other helm chart and i want to have a common values file in this libary. I have thought to do it using a external file and load it like below but i haven't be able to do it. What i am doing wrong? Thanks
##defaultRoutesHelm.yaml
route:
dev:
path: dev.es
labels:
router: alpha
staging:
path: staging.es
labels:
router: beta
--
{{- $helmRoute := .Files.Get "config/defaultRoutesHelm.yaml" | fromYaml }}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ .Release.Name }}-configmap
data:
path: {{get $helmRoute 'route.dev.path'}}
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
