Sprites
Read this when you:
- choose
provider: sprites; - debug Sprites token resolution, the
spriteCLI, the SSH proxy, or bootstrap; - change Sprites lease creation, status, sync, or cleanup.
provider: sprites provisions a Sprites Linux microVM and adapts it into a normal Crabbox SSH lease. Sprites owns the microVM lifecycle and the sprite proxy transport. Crabbox owns local config, slugs, repo claims, per-lease SSH keys, rsync-based sync, command execution, timing summaries, and normalized list/status output. There is no Crabbox coordinator (broker) path for Sprites — it always runs direct from the CLI.
#Auth
Set a Sprites token through the environment or user config. Do not commit tokens to repo config.
export SPRITES_TOKEN=...
Crabbox resolves the token from the first set of these, in order:
CRABBOX_SPRITES_TOKENSPRITES_TOKENSPRITE_TOKENSETUP_SPRITE_TOKENsprites.tokenin config
Install and authenticate the Sprites CLI before first use. Crabbox calls the Sprites HTTP API for sprite create/get/list/delete, and shells out to the local sprite CLI for sprite --version (a readiness check), sprite exec (running the SSH bootstrap inside the microVM), and sprite proxy (the SSH transport).
#Config
provider: sprites
target: linux
sprites:
apiUrl: https://api.sprites.dev
workRoot: /home/sprite/crabbox
Defaults: apiUrl is https://api.sprites.dev and workRoot is /home/sprite/crabbox. The API URL and work root also read from the environment:
CRABBOX_SPRITES_API_URLorSPRITES_API_URL→sprites.apiUrlCRABBOX_SPRITES_WORK_ROOT→sprites.workRoot
Custom API URLs require HTTPS unless the host is literal loopback. Userinfo, queries, and fragments are rejected, and authenticated requests cannot follow redirects to another origin.
Equivalent one-off flags:
crabbox warmup --provider sprites
crabbox run --provider sprites --sprites-work-root /home/sprite/crabbox -- pnpm test
crabbox run --provider sprites --sprites-api-url https://api.sprites.dev -- pnpm test
crabbox ssh --provider sprites --id <slug>
crabbox status --provider sprites --id <slug>
crabbox stop --provider sprites <slug>
#Behavior
warmupcreates a sprite namedcrabbox-<...>and a local Crabbox claim.- During bootstrap Crabbox ensures OpenSSH server, Git, rsync, tar, and python3 are installed (via
apt-getwhen missing), appends the per-lease public key to/home/sprite/.ssh/authorized_keys, and startssshd— registering it as asprite-envservice when that tool is available so it survives restarts. - The lease SSH user is
sprite. runcreates or reuses a sprite, syncs the current Git manifest over SSH, and runs the command through Crabbox's standard SSH executor.sshprints a command that usessprite proxy -s %h -W 22as the SSHProxyCommand.status,list, andstopoperate on Sprites resources mapped to local claims or provider labels;listonly shows sprites whose name starts withcrabbox-.stopdeletes the sprite and removes the local claim after provider cleanup succeeds.
#Boundaries
- Linux only.
- No coordinator; auth is local/provider-native.
- No VNC, desktop, browser, or code-server.
--tailscaleis rejected: Sprites exposes SSH throughsprite proxy.--classand--typedo not apply to Sprites.- Actions hydration works, since the sprite is a normal Linux SSH target.
#Troubleshooting
provider=sprites requires SPRITES_TOKEN, SPRITE_TOKEN, SETUP_SPRITE_TOKEN, or CRABBOX_SPRITES_TOKEN: set one of those tokens (orsprites.tokenin config).provider=sprites requires the sprite CLI on PATH and authenticated: install the authenticated Sprites CLI and ensurespriteis onPATH. Crabbox probes this withsprite --version.sprite proxyfailures mean SSH cannot reach the microVM even when API calls succeed. Runcrabbox status --provider sprites --id <slug> --waitto retry the idempotent SSH bootstrap.- Slow first boot usually means package install inside the sprite is still running. Kept leases reuse the installed OpenSSH/rsync packages.
- The work root must resolve to a dedicated absolute path (broad paths such as
/,/home,/tmpare rejected). Prefer a subdirectory under the sprite user's home, for example/home/sprite/crabbox.