Docker

Slurm-web publishes OCI images for the agent and gateway on GitHub Container
Registry (GHCR). Docker can run these images directly with
docker run, or with the reference Compose stack using docker compose.
For full walkthroughs, see Quickstart with containers and Quickstart with Compose.
Images
-
ghcr.io/rackslab/slurm-web-agent— cluster agent -
ghcr.io/rackslab/slurm-web-gateway— web gateway and UI
Use the latest tag for evaluation or a release tag matching a git tag (for
example v7.0.0).
docker run
This section describes how to run Slurm-web with standalone docker run
commands: persistent storage layout, file ownership requirements and the
typical commands used to start and check the agent and gateway containers.
Storage layout
Agent and gateway read configuration from /etc/slurm-web/ and
secrets from /var/lib/slurm-web/ inside containers. Those paths are
fixed; the container command decides where the data is stored on the host.
For production-style run commands, keep the same paths on the host:
| Host | Container path | Purpose |
|---|---|---|
|
|
|
|
|
|
Slurm-web containers run as an unprivileged user. With bind mounts, the numeric UID and GID from the host are preserved, so the container process must run with the UID/GID that owns writable files on the host.
Create a slurm-web system user on the host and let the
operating system allocate its UID/GID for the secrets directory:
$ sudo useradd --system --user-group --home-dir /var/lib/slurm-web --create-home slurm-web
$ sudo chown -R slurm-web:slurm-web /var/lib/slurm-web
Create the configuration directory:
$ sudo mkdir -p /etc/slurm-web
$ sudo chown -R root:slurm-web /etc/slurm-web
$ sudo chmod 0750 /etc/slurm-web
Then run Slurm-web containers with:
--user $(id -u slurm-web):$(id -g slurm-web)
|
As an alternative to bind mounts, you can use Docker/Podman named volumes
for persistent data. The in-container paths stay the same; only the
Then replace the secrets bind mount:
If you also use a named volume for configuration, create and populate it with
|
Deploy
For a complete deployment walkthrough with run commands, see
Quickstart with containers.
Pull the images:
$ docker pull ghcr.io/rackslab/slurm-web-agent:latest
$ docker pull ghcr.io/rackslab/slurm-web-gateway:latest
Typical commands:
$ docker run -d --name slurm-web-agent [OPTIONS] ghcr.io/rackslab/slurm-web-agent:latest
$ docker run -d --name slurm-web-gateway [OPTIONS] ghcr.io/rackslab/slurm-web-gateway:latest
$ docker run --rm [OPTIONS] ghcr.io/rackslab/slurm-web-agent:latest connect-check
Docker Compose
The reference mono-cluster Compose stack is defined in
containers/compose.yaml in the source repository (agent, gateway,
optional Redis and Prometheus).
Download compose.yaml into your working directory:
$ curl -fsSL -o compose.yaml https://raw.githubusercontent.com/rackslab/Slurm-web/main/containers/compose.yaml
Storage layout
The reference stack keeps configuration and secrets next to
compose.yaml for a self-contained evaluation:
| Host (project dir) | Container path | Purpose |
|---|---|---|
|
|
|
|
|
|
Create the project layout with:
$ mkdir -p conf keys
With bind mounts, the container process must run with a UID/GID allowed to
write in the host ./keys/ directory. The reference Compose file uses
LOCAL_UID and LOCAL_GID to set this runtime user, so define these variables
with the host owner of ./keys/ (typically your login user) for
compose run, compose up and compose restart commands:
$ LOCAL_UID=$(id -u) LOCAL_GID=$(id -g) docker compose up -d
|
You can also replace bind mounts with named volumes. For example, replace the secrets bind mount:
The |
Deploy
For a complete deployment walkthrough with the reference stack, see Quickstart with Compose.
Pull the images:
$ docker compose pull
Typical commands:
$ LOCAL_UID=$(id -u) LOCAL_GID=$(id -g) docker compose run --rm gateway gen-jwt-key
$ LOCAL_UID=$(id -u) LOCAL_GID=$(id -g) docker compose run --rm gateway gen-session-key
$ LOCAL_UID=$(id -u) LOCAL_GID=$(id -g) docker compose up -d
$ LOCAL_UID=$(id -u) LOCAL_GID=$(id -g) docker compose run --rm agent connect-check