srest

srest is a TUI (terminal user interface) client for interacting remotely with the Slurm REST API (the HPC workload manager).

It lets Slurm administrators and users query cluster and job state without SSH-ing into the master node, using only HTTP requests to slurmrestd.

About

srest is a terminal user interface (TUI) built with Bubble Tea that turns the Slurm REST API into a live, interactive dashboard. It lets you:

It is written in Go, styled with Lip Gloss, and speaks directly to slurmrestd using JSON Web Token authentication — no SSH, no node login.

Status

srest is under active development. Current features:

Features

Tabs (navigate with tab/shift+tab or [/], esc returns to Dashboard):

Key bindings

Key Action
q / Ctrl+C quit
tab / ], shift+tab / [ next / previous tab
esc go to Dashboard
/ filter the current table
r refresh (Jobs tab)
? toggle help

Stack

Architecture

Follows the standard Go layout with a strict separation of responsibilities:

.
├── main.go                  # Entry point: configuration + Bubble Tea startup
└── internal/
    ├── config/              # Configuration loading (environment)
    ├── api/                 # Pure HTTP client (no UI)
    └── ui/                  # Bubble Tea model, view and update

Requirements

Installation and usage

go build -o srest .

Configuration

srest is configured through environment variables:

Variable Required Description
SLURM_URL No Base URL of slurmrestd. Defaults to http://localhost:6820.
SLURM_JWT Yes* JWT token for the X-SLURM-USER-TOKEN header.
SLURM_USER_NAME No User for X-SLURM-USER-NAME. Defaults to the current OS user.
SLURM_API_VERSION No API version to use (e.g. v0.0.45). If omitted, it is auto-detected.

* For endpoints requiring authentication. Can be omitted on clusters with a JWT-less slurmrestd.

SLURM_URL=http://localhost:6820 \
SLURM_JWT=<token> \
SLURM_USER_NAME=slurm \
./srest

Press q (or Ctrl+C) to quit.

Test Lab

To try srest against a real Slurm cluster (with slurmctld, slurmdbd and slurmrestd) without setting up infrastructure, see:

Tests

go test ./...                  # unit tests (the integration one skips itself)

Integration test against a real slurmrestd (requires SLURM_URL and SLURM_JWT):

SLURM_URL=http://localhost:6820 SLURM_JWT=<token> \
  go test ./internal/api -run TestPingIntegration -v

License

Apache License 2.0.