Skip to content

Slurm: build a worker image with Apptainer and cwltool (slurmd-cwl), ReturnToService=2 - #144

Merged
Vorkosik merged 1 commit into
EOEPCA:deploy-developfrom
Vorkosik:slurm-worker-image
Nov 25, 2026
Merged

Vorkosik merged 1 commit into
EOEPCA:deploy-developfrom
Vorkosik:slurm-worker-image

Conversation

@Vorkosik

Copy link
Copy Markdown
Contributor

Summary

First of two steps that prepare the Slurm workers for CWL Application Packages submitted through the Slurm REST API (EOEPCA/processing#11, input for the ZOO runner of EOEPCA/processing#8). This pull request builds and publishes the image but does not use it yet, so the running cluster does not change apart from ReturnToService. The workers switch to the image in a second pull request, after the package exists and is public.

File Purpose
images/slurmd-cwl/Dockerfile Slinky slurmd:26.05.4-ubuntu26.04 plus Apptainer (Ubuntu 26.04 archive, 1.4.5), cwltool 3.3.20260925135507 in /opt/cwl (resolved packages in /opt/cwl/requirements.lock), nodejs
images/slurmd-cwl/VERSION Image tag, 26.05.4-ubuntu26.04-cwl.1. The first part must match the Slurm build of the other components
.github/workflows/build-slurmd-cwl-image.yaml Builds the image on pull requests, and builds and pushes it to ghcr.io/eoepca/eoepca-plus/slurmd-cwl:<VERSION> on deploy-develop. Same pattern as build-opa-bundle.yaml
argocd/eoepca/slurm/parts/values-slurm.yaml ReturnToService=2

Why ReturnToService=2

The operator sets a node DOWN while its pod restarts. With the Slurm default ReturnToService=0 the node stays DOWN until an admin resumes it. After the merge of #143 the worker pod restarted for the pinned image, and slinky-0 stayed DOWN for about 36 minutes until it was resumed by hand. With ReturnToService=2, a DOWN node returns to service as soon as its slurmd registers with a valid configuration.

On a local kind cluster (Slinky 1.2, Slurm 26.05.4), after deleting the worker pod:

  • ReturnToService=0: the node went DOWN ("slurm-operator: Pod is terminating") and stayed DOWN for the two minutes observed;
  • ReturnToService=2: the node went DOWN and was idle again 10 seconds later.

The setting is applied in place by the reconfigure sidecar (controller.inplaceReconfigure: true), without a pod restart. That is why it comes in this pull request: it must be active before the second pull request restarts the worker pod.

Note: with 2, a node that an admin sets DOWN on purpose also returns when its slurmd re-registers ("The node could have been set DOWN for any reason", slurm.conf(5)). The manual describes ReturnToService for DOWN nodes only, so DRAIN is the way to take a node out of service (not tested here).

Why the Ubuntu package of Apptainer

The upstream Apptainer 1.5.4 .deb depends on libfuse3-3 and libsubid4. Ubuntu 26.04, the base of the Slinky images, has renamed both (libfuse3-4, libsubid5), so the upstream package does not install. Ubuntu 26.04 ships Apptainer 1.4.5 in its archive, signed and updated with the distribution. Apptainer runs unprivileged with user namespaces; no setuid helper is installed.

Validation performed

  • Image built locally (445 MB, base image 320 MB). apptainer --version 1.4.5, cwltool --version 3.3.20260925135507.
  • Standalone, privileged like the Slinky pod: a CWL tool with alpine:3.22 ran through Apptainer as an unprivileged uid.
  • helm template of the slurm chart 1.2.0 with the values file: ReturnToService=2 in the controller configuration, the NodeSet image unchanged.
  • The ReturnToService test above.
  • The GitHub workflow itself was not run.

After the merge

  1. The workflow runs on deploy-develop and pushes ghcr.io/eoepca/eoepca-plus/slurmd-cwl:26.05.4-ubuntu26.04-cwl.1.
  2. Package visibility: the cluster pulls without credentials only if the GHCR package is public. Please make it public after the first push, or confirm that the organisation publishes new packages as public.
  3. Then the second pull request (slurm-worker-cwl) switches the NodeSet to the image.

@Vorkosik Vorkosik self-assigned this Nov 25, 2026
@Vorkosik
Vorkosik merged commit 399140c into EOEPCA:deploy-develop Nov 25, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant