Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ jobs. Personal, uncommitted instructions belong in `CLAUDE.local.md` (gitignored
`-vvv` under `RUNNER_DEBUG`), run `sind doctor`, export `SIND_REALM` from the `realm`
input, and create clusters (`scripts/create.sh`). Outputs: `clusters`, `version`.
- `scripts/install.sh`: resolves `latest` from the redirect of the latest release page
(not the rate-limited API), enforces `MIN_VERSION`, downloads `sind-linux-amd64` into
`~/.local/bin`, and checks `sind version --json`.
(not the rate-limited API), enforces `MIN_VERSION`, downloads `sind-linux-amd64` (or
`sind-linux-arm64` on ARM64 runners, sind releases after v0.9.0) into `~/.local/bin`,
and checks `sind version --json`.
- `scripts/create.sh`: each `clusters` entry is a config file path (scalar) or an inline
config (map). It creates each cluster, prints its status, and writes the `clusters`
output.
Expand Down
43 changes: 41 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,10 @@ jobs:

## Requirements

- A Linux x64 runner, such as `ubuntu-latest`. sind publishes no binaries for
other platforms.
- A Linux x64 or ARM64 runner, such as `ubuntu-latest` or `ubuntu-24.04-arm`.
The action installs the sind binary for the runner's architecture. ARM64
runners need a sind release after v0.9.0, the first with linux/arm64
binaries and node images.
- Docker and cgroup v2, which `sind doctor` checks before any cluster is
created.
- `bash`, `curl`, `jq` and [mikefarah `yq`](https://github.com/mikefarah/yq) v4.
Expand Down Expand Up @@ -106,6 +108,43 @@ jobs:
if: always()
```

## Slurm Versions

Clusters use sind's default node image, `ghcr.io/gsi-hpc/sind-node:latest`, which
carries the newest supported Slurm release line. sind also publishes an image per
supported release line, tagged `<YY>.<MM>` (e.g. `25.11`). To pin a release line,
or test against several, set the image in the cluster config:

```yaml
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
slurm: ['25.11', '26.05']
steps:
- uses: actions/checkout@v7

- uses: GSI-HPC/sind-action@v2
with:
clusters: |
- kind: Cluster
name: dev
defaults:
image: ghcr.io/gsi-hpc/sind-node:${{ matrix.slurm }}
nodes:
- controller
- worker: 2

- run: sind exec dev -- srun -N2 hostname

- uses: GSI-HPC/sind-action/cleanup@v2
if: always()
```

See [Official images](https://gsi-hpc.github.io/sind/container-images/building-images/#official-images)
for the available tags.

## AI disclosure

This project is developed with the help of AI coding tools. Since September 2026,
Expand Down
25 changes: 18 additions & 7 deletions scripts/install.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
#!/usr/bin/env bash
set -euo pipefail

# sind releases only a Linux x86-64 binary.
if [[ "$(uname -s)/$(uname -m)" != "Linux/x86_64" ]]; then
echo "::error::sind runs only on Linux x64 runners, not on $(uname -s) $(uname -m)"
exit 1
fi
# sind releases Linux binaries for x86-64 and, after v0.9.0, arm64.
case "$(uname -s)/$(uname -m)" in
Linux/x86_64) ARCH=amd64 ;;
Linux/aarch64 | Linux/arm64) ARCH=arm64 ;;
*)
echo "::error::sind runs only on Linux x64 and ARM64 runners, not on $(uname -s) $(uname -m)"
exit 1
;;
esac

REPO_URL="https://github.com/GSI-HPC/sind"
VERSION="${SIND_VERSION:-latest}"
Expand Down Expand Up @@ -36,9 +40,16 @@ if [[ "$(printf '%s\n' "$MIN_VERSION" "$VERSION" | sort -V | head -n1)" != "$MIN
exit 1
fi

echo "Installing sind ${VERSION}..."
# v0.9.0 and earlier publish only sind-linux-amd64.
LAST_AMD64_ONLY="v0.9.0"
if [[ "$ARCH" == "arm64" && "$(printf '%s\n' "$LAST_AMD64_ONLY" "$VERSION" | sort -V | tail -n1)" == "$LAST_AMD64_ONLY" ]]; then
echo "::error::sind ${VERSION} has no linux/arm64 binary; ARM64 runners need a sind release after ${LAST_AMD64_ONLY}"
exit 1
fi

echo "Installing sind ${VERSION} (linux/${ARCH})..."

DOWNLOAD_URL="${REPO_URL}/releases/download/${VERSION}/sind-linux-amd64"
DOWNLOAD_URL="${REPO_URL}/releases/download/${VERSION}/sind-linux-${ARCH}"
INSTALL_DIR="${HOME}/.local/bin"
mkdir -p "$INSTALL_DIR"

Expand Down
Loading