helm create first-chart- Change into the
first-chartdirectory and look around - Delete the
templatesdirectory
- (re)Make a
templatesdirectory and change into the directory - Create a
configmap.yamlfile - Copy and paste the ConfigMap below:
apiVersion: v1
kind: ConfigMap
metadata:
name: first-chart-configmap
data:
port: "8080"helm install .- See your helm chart with
helm ls - See all ConfigMaps with
kubectl get cm - See your ConfigMap data with
kubectl describe cm first-chart-configmap - Delete the helm chart with
helm delete <helm_generated_name_of_chart>
- Edit your ConfigMap to generate the name dynamically with a Helm template directive
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ .Release.Name }}-configmap
data:
port: "8080"helm install .- See your helm chart with
helm ls - See all configmaps with
kubectl get cm - Delete the helm chart with
helm delete <helm_generated_name_of_chart>
Resources: