@slayzone/cli
v0.44.0
Published
SlayZone CLI — run, list and target SlayZone hubs; drive tasks, ptys and projects
Readme
@slayzone/cli (slay)
Command-line control for SlayZone hubs, plus tasks, terminals and projects.
npm install -g @slayzone/cliHubs on this machine
slay hub create <name> # create a hub in this directory and keep it running
slay hub ls # every hub running on this machine
slay hub logs <name>
slay hub stop <name> # stop it, keep it registered
slay hub start <name> # bring a stopped hub back
slay hub rm <name> # stop it and remove its registrationhub create registers the hub with your OS service manager (launchd on macOS,
systemd --user on Linux), so it restarts if it crashes and starts again when you
log in. Names are unique per machine — create fails if one already exists. To
run a hub in the foreground instead, use npx @slayzone/hub.
Computers on this machine
A computer is an execution node: it dials out to a hub and runs terminals, agents and git there. Mint a join token on the hub, then:
slay computer create <name> --token <szjt1…> # install it here and keep it running
slay computer ls # every computer installed on this machine
slay computer logs <name>
slay computer stop <name> # stop it, keep it registered
slay computer start <name> # bring a stopped computer back
slay computer rm <name> # stop it and remove its registrationThe token embeds the hub URL, so --token is the only configuration needed. It is stored in <root>/config.json (owner-only) — never in
the service unit. --root <dir> picks where the computer's config, credentials and
logs live (default: the current directory), and --allow <dir> (repeatable) sets
the filesystem roots it may touch. One computer per root.
create waits until the computer has actually reached its hub, and unregisters
itself again if it cannot — so a bad token fails loudly instead of leaving a
service that retries forever. rm leaves the computer's data on disk and does NOT
revoke it on the hub; revoke it there if the machine is going away.
Targeting a hub
slay hub use <name|url> # point this CLI at a hub
slay hub current # which hub am I pointed at?
slay --hub staging tasks list # one-off overrideGPL-3.0-only. Source: https://github.com/debuglebowski/slayzone
