From 8b08a65f0c7028671c657dc5c81cfc7198a6faf6 Mon Sep 17 00:00:00 2001 From: trana Date: Mon, 14 Oct 2024 14:27:59 +0200 Subject: [PATCH] Fixes #27: regression fix of envfile.properties parent folder created before --- pkg/slurm/Create.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/slurm/Create.go b/pkg/slurm/Create.go index 9f7eed9..853e2f9 100644 --- a/pkg/slurm/Create.go +++ b/pkg/slurm/Create.go @@ -81,7 +81,6 @@ func (h *SidecarHandler) SubmitHandler(w http.ResponseWriter, r *http.Request) { commstr1 := []string{"singularity", "exec", "--containall", "--nv", singularityMounts, singularityOptions} - envs := prepareEnvs(spanCtx, h.Config, data, container) image := "" CPULimit, _ := container.Resources.Limits.Cpu().AsInt64() @@ -107,6 +106,9 @@ func (h *SidecarHandler) SubmitHandler(w http.ResponseWriter, r *http.Request) { os.RemoveAll(filesPath) return } + + // prepareEnvs creates a file in the working directory, that must exist. This is created at prepareMounts. + envs := prepareEnvs(spanCtx, h.Config, data, container) image = container.Image if image_uri, ok := metadata.Annotations["slurm-job.vk.io/image-root"]; ok {