mirror of
https://github.com/truenas/charts.git
synced 2026-11-26 15:26:05 +00:00
18 lines
405 B
Smarty
18 lines
405 B
Smarty
{{/*
|
|
Retrieve volume configuration
|
|
*/}}
|
|
{{- define "common.volumeConfig" -}}
|
|
{{- $values := . -}}
|
|
{{- if hasKey $values "name" }}
|
|
- name: {{ $values.name }}
|
|
{{- if $values.emptyDirVolumes -}}
|
|
emptyDir: {}
|
|
{{- else -}}
|
|
hostPath:
|
|
path: {{ template "common.configuredHostPath" $values }}
|
|
{{- end -}}
|
|
{{- else -}}
|
|
{{- fail "Name must be specified for Volume Configuration" -}}
|
|
{{- end -}}
|
|
{{- end -}}
|