fix: declare one k3s pod volume per storage entry

Mounting one storage entry at two container paths named the same pod volume twice, which Kubernetes rejects as a duplicate, so the chart never applied even though the k3s documentation offers mounting a claim "into the same app at multiple subpaths" as a supported shape. A pod now declares each entry once and binds it at each path it was mounted at. Rendering the chart in a test also surfaced that a cron schedule was emitted unquoted, so any schedule beginning with `*` produced a manifest that could not be parsed at all.
This commit is contained in:
Jose Diaz-Gonzalez committed 2026-09-21 23:35:25 -04:00
1 parent b612285392
commit 14bdc1b2bd
7 files changed
+387 -23

No files matched your search

@@ -163,7 +163,10 @@ spec:
serviceAccountName: {{ $.Values.global.app_name }}
{{- if $config.volumes }}
volumes:
{{- $seen := dict }}
{{- range $volume := $config.volumes }}
{{- if not (hasKey $seen $volume.name) }}
{{- $_ := set $seen $volume.name true }}
- name: {{ $volume.name }}
{{- if $volume.empty_dir }}
emptyDir:
@@ -179,8 +182,9 @@ spec:
claimName: {{ $volume.persistent_claim.claim_name }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}
schedule: {{ $config.cron.schedule }}
schedule: {{ $config.cron.schedule | quote }}
startingDeadlineSeconds: 60
successfulJobsHistoryLimit: 10
suspend: {{ $config.cron.suspend }}
@@ -179,7 +179,10 @@ spec:
serviceAccountName: {{ $.Values.global.app_name }}
{{- if $config.volumes }}
volumes:
{{- $seen := dict }}
{{- range $volume := $config.volumes }}
{{- if not (hasKey $seen $volume.name) }}
{{- $_ := set $seen $volume.name true }}
- name: {{ $volume.name }}
{{- if $volume.empty_dir }}
emptyDir:
@@ -195,5 +198,6 @@ spec:
claimName: {{ $volume.persistent_claim.claim_name }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}