Skip to content

Instantly share code, notes, and snippets.

@carlessanagustin
Created November 10, 2021 13:57
Show Gist options
  • Save carlessanagustin/b19dfcc208ad1e387e2cb180ddfa21b4 to your computer and use it in GitHub Desktop.
Save carlessanagustin/b19dfcc208ad1e387e2cb180ddfa21b4 to your computer and use it in GitHub Desktop.
k8s.initContainers.yaml
### START: initContainers
initContainers:
- name: init-steps
command: ["sleep", "14400"]
image: alpine:latest
imagePullPolicy: IfNotPresent
resources:
limits:
memory: "128Mi"
cpu: "500m"
### START: initContainers.volumeMounts
{{- if or .Values.configMaps .Values.persistantVolume }}
volumeMounts:
{{- if .Values.configMaps }}
{{- range .Values.configMaps }}
- name: {{ .name }}
mountPath: {{ .mountPath }}
{{- if .subPath }}
subPath: {{ .subPath | quote }}
{{- end }}
{{- if .readOnly }}
readOnly: {{ .readOnly }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}
### END: initContainers.volumeMounts
### END: initContainers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment