From 32b9fe7fab3698e8763141cedc421ba19565cc0e Mon Sep 17 00:00:00 2001 From: Jake Smith Date: Wed, 13 Dec 2023 15:13:00 +0000 Subject: [PATCH] HPCC-31016 Use unique thorworker working dir in k8s Signed-off-by: Jake Smith --- helm/hpcc/templates/_helpers.tpl | 3 +++ helm/hpcc/templates/thor.yaml | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/helm/hpcc/templates/_helpers.tpl b/helm/hpcc/templates/_helpers.tpl index e1d6769c525..5822b99caf7 100644 --- a/helm/hpcc/templates/_helpers.tpl +++ b/helm/hpcc/templates/_helpers.tpl @@ -308,6 +308,9 @@ Add ConfigMap volume mount for a component mountPath: /tmp - name: {{ .name }}-hpcctmp-volume mountPath: /var/lib/HPCCSystems +{{- if .tmpSubPath }} + subPath: {{ .tmpSubPath | quote }} +{{- end }} - name: {{ .name }}-configmap-volume mountPath: /etc/config {{- end -}} diff --git a/helm/hpcc/templates/thor.yaml b/helm/hpcc/templates/thor.yaml index fe80bde7395..5e6a4dac6f1 100644 --- a/helm/hpcc/templates/thor.yaml +++ b/helm/hpcc/templates/thor.yaml @@ -244,7 +244,7 @@ data: {{ include "hpcc.mergeEnvironments" $configCtx.me.env | indent 12 }} workingDir: /var/lib/HPCCSystems volumeMounts: -{{ include "hpcc.addConfigMapVolumeMount" $configCtx.me | indent 12 }} +{{ include "hpcc.addConfigMapVolumeMount" (deepCopy $configCtx.me | merge (dict "tmpSubPath" $containerNum)) | indent 12 }} {{ include "hpcc.addVolumeMounts" $configCtx | indent 12 }} {{ include "hpcc.addSecretVolumeMounts" $configCtx | indent 12 }} {{ include "hpcc.addCertificateVolumeMount" (dict "root" $configCtx.root "name" $configCtx.me.name "component" "thorworker") | indent 12 }}