mirror of
https://github.com/truecharts/library-charts.git
synced 2026-07-05 01:26:21 -03:00
no point to try tpl on persistence item name
This commit is contained in:
@@ -5,6 +5,6 @@
|
||||
{{- if not $vol.volumeSpec -}}
|
||||
{{- fail (printf "You have defined custom persistence type but no <volumeSpec> was given on item (%s)" $index) -}}
|
||||
{{- end }}
|
||||
- name: {{ tpl (toString $index) $root }}
|
||||
- name: {{ $index }}
|
||||
{{- tpl ( toYaml $vol.volumeSpec ) $root | nindent 2 -}}
|
||||
{{- end -}}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{{- $index := .index -}}
|
||||
{{- $vol := .volume -}}
|
||||
{{- $root := .root }}
|
||||
- name: {{ tpl (toString $index) $root }}
|
||||
- name: {{ $index }}
|
||||
{{- if not (or $vol.medium $vol.sizeLimit) }}
|
||||
emptyDir: {}
|
||||
{{- else }}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{{- $index := .index -}}
|
||||
{{- $vol := .volume -}}
|
||||
{{- $root := .root }}
|
||||
- name: {{ tpl (toString $index) $root }}
|
||||
- name: {{ $index }}
|
||||
hostPath:
|
||||
path: {{ required (printf "hostPath not set on item %s" $index) $vol.hostPath }}
|
||||
{{- with $vol.hostPathType }}
|
||||
|
||||
@@ -2,6 +2,6 @@
|
||||
{{- $index := .index -}}
|
||||
{{- $vol := .volume -}}
|
||||
{{- $root := .root }}
|
||||
- name: {{ tpl (toString $index) $root }}
|
||||
- name: {{ $index }}
|
||||
|
||||
{{- end -}}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{{- $index := .index -}}
|
||||
{{- $vol := .volume -}}
|
||||
{{- $root := .root }}
|
||||
- name: {{ tpl (toString $index) $root }}
|
||||
- name: {{ $index }}
|
||||
nfs:
|
||||
server: {{ required (printf "NFS Server not set on item %s" $index) $vol.server }}
|
||||
path: {{ required (printf "NFS Path not set on item %s" $index) $vol.path }}
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
{{- $pvcName = . -}}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
- name: {{ tpl (toString $index) $root }}
|
||||
- name: {{ $index }}
|
||||
persistentVolumeClaim:
|
||||
claimName: {{ tpl $pvcName $root }}
|
||||
{{- end -}}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
{{- $vol := .volume -}}
|
||||
{{- $root := .root -}}
|
||||
{{- $objectName := tpl (required (printf "objectName not set for persistence item %s" (toString $index)) $vol.objectName) $root }}
|
||||
- name: {{ tpl (toString $index) $root }}
|
||||
- name: {{ $index }}
|
||||
secret:
|
||||
secretName: {{ $objectName }}
|
||||
{{- with $vol.defaultMode }}
|
||||
|
||||
Reference in New Issue
Block a user