Skip to main content

SLURM batch fixture

This Showcase is a reproducible adapter fixture, not a replacement for an HPC cluster. It starts an isolated AkôFlow daemon, puts small sbatch and singularity fixture commands ahead of the daemon's PATH, and runs the generated batch script inside a disposable Alpine container. The activity writes result.txt; the normal SLURM adapter observes its completion sentinel and persists the artifact manifest.

Use it to verify a local checkout after changing the SLURM adapter, batch-script generation, or artifact observation. Do not use it as evidence that a real cluster's login node, SSH proxy, allocation, sacct accounting, squeue, scancel, shared filesystem, account, QoS, or partition policy is configured correctly. Use Connect an HPC and SLURM cluster for that site-approved procedure.

Prerequisites

  • Go, Docker, curl, and POSIX sh on the machine where this repository is checked out.
  • Port 18082 unused for the isolated daemon.
  • Permission for Docker to pull and run alpine:3.20.

The fixture is intentionally local and disposable. It writes all database and generated state under examples/slurm/local-fixture/.runtime, scripts, akoflow-*.status, akoflow-*.log, and akoflow-workspaces; those paths are ignored by Git.

Download the inputs

Inspect it with AkôFlow Desktop

  1. Start the fixture daemon as described below, then configure Desktop to use http://127.0.0.1:18082/akoflow-api.
  2. Under Infrastructure → Environments, import or recreate environment.yaml. Confirm the slurm runtime is bound to the batch partition.
  3. Create the scope and empty topology, then import workflow.yaml under Workflows → Definitions.
  4. Import the manual plan or create the same one-activity assignment to slurm-fixture-partition. Start a Real execution.
  5. Open the completed run. The activity's artifacts must list the created result.txt file.

Desktop is optional for this fixture. The API path below submits the same versioned files and is the reproducible verification route.

Verify the result

The API returns an accepted run; poll the final command until it prints completed. The run contains one settled activity. Its artifact manifest must contain:

result.txt
22 bytes
sha256:c8920140392a98da804ba516844aa2f241ab8332487e5173c4fd57d9e3e73292

The file content is:

Akoflow Slurm fixture

This evidence was recorded from the checked-in fixture on 2026-09-12. Timing varies with local compilation and Docker startup, so it is not a queue-time or performance benchmark. The workflow has no data dependency, therefore transferred bytes are zero.

Clean up

Stop the first terminal with Ctrl+C. If you no longer need the local fixture evidence, remove only its generated paths:

rm -rf examples/slurm/local-fixture/.runtime \\
examples/slurm/local-fixture/scripts \\
examples/slurm/local-fixture/akoflow-workspaces
rm -f examples/slurm/local-fixture/akoflow-*.status \\
examples/slurm/local-fixture/akoflow-*.log

Never apply this cleanup pattern to an actual cluster workspace: those paths are owned by this fixture only.

Troubleshooting

SymptomCause and recovery
docker: not found or access deniedInstall Docker and ensure the current user can run docker info. This fixture needs Docker only to execute the generated script in a disposable Linux environment.
Port 18082 is already in useStop the process using it, or start the fixture with AKOFLOW_HTTP_ADDRESS=127.0.0.1:18083 and set AKOFLOW_API_URL to the corresponding API base URL.
The run remains queuedCheck that the first terminal is still running and that sbatch was invoked from the fixture's bin directory. Do not start a second fixture daemon against the same .runtime directory.
The artifact is absentInspect examples/slurm/local-fixture/akoflow-*.log and .status; then confirm Docker can pull alpine:3.20.

Related material: SLURM/HPC connection guide, local direct execution, and workflow runs.