From 6ffe4419834df320c0de7655be620da5a079a653 Mon Sep 17 00:00:00 2001 From: Juana De La Cuesta Date: Thu, 6 Mar 2025 10:34:21 +0100 Subject: [PATCH] [gh-24931] Return dummy function for moving processes when running rootless (#24944) * fix: stop executor launch if nomad doesnt have permissions * func: return move function if c group is not enabled --- drivers/shared/executor/executor_universal_linux.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/shared/executor/executor_universal_linux.go b/drivers/shared/executor/executor_universal_linux.go index 3c113f6d0..b399b557e 100644 --- a/drivers/shared/executor/executor_universal_linux.go +++ b/drivers/shared/executor/executor_universal_linux.go @@ -156,6 +156,9 @@ func (e *UniversalExecutor) configureResourceContainer( return moveProcess, deleteCgroup, err } moveProcess, deleteCgroup = e.enterCG1(cgroup, command.CpusetCgroup()) + case cgroupslib.OFF: + deleteCgroup = func() {} + moveProcess = func() error { return nil } default: e.configureCG2(cgroup, command) // configure child process to spawn in the cgroup