Skip to content

docs: describe SSH that sets itself up and the CLI inside a workspace - #22

Merged
jona62 merged 9 commits into
mainfrom
docs/gap-report-ssh-vm
Sep 30, 2026
Merged

jona62 merged 9 commits into
mainfrom
docs/gap-report-ssh-vm

Conversation

@jona62

@jona62 jona62 commented Sep 29, 2026

Copy link
Copy Markdown
Contributor

These are the docs for the rig CLI gap-report fixes:

  • the CLI changes in rigbox-dev/cli#201;
  • the SSH gateway and Claude Code catalog changes in jona62/rig-mvp#483;
  • the VM bridge limits in jona62/rig-mvp#482.

What changes

  • SSH access (guides/ssh-access.mdx, rewritten):
    • rig login, rig ssh add and workspace spawn/start/restart/ssh-info set up SSH themselves. They register the key, write a Host entry per workspace in ~/.config/rigbox/ssh_config, and trust the gateway's host keys. ssh <workspace> then works from a terminal, an editor or the Claude desktop app.
    • The guide also covers rig config set ssh-setup false, the stopped-workspace message on stderr, ssh -t with a command, and SFTP, scp and rsync by alias.
    • It says that port, agent and X11 forwarding aren't available.
    • The key, file-transfer and troubleshooting pages, the install guide, the quickstart, the workspace guide and the security page are updated to match. Legacy anchors are kept.
  • Inside a workspace (cli-reference/execution-modes.mdx):
    • which commands work there, and the one-line refusal for laptop-only ones;
    • --workspace defaulting to the current workspace;
    • rig deploy deploying into the workspace it runs in;
    • what the bridge won't serve, or serves read-only.
    • The guides for the CLI, deploy, configuration, setup scripts, service specs and app logs link to it, and so does the security page.
  • rig update (guides/install-cli.mdx): it replaces the running binary from the public mirror, inside workspaces too. The page covers --version, the update notice, RIGBOX_NO_UPDATE_CHECK and the workspace's own update timer.
  • Managed proxy:
    • each client gets its base URL: Anthropic clients take the proxy root, and OpenAI-compatible ones take /v1;
    • rig proxy off only unsets variables that point at the proxy.
  • Coding agents:
    • rig recipe app install --ref claude -w <ws> adds an agent to an existing workspace;
    • the guide lists all six built-in agents with their routing;
    • the Claude Code item keeps the user's own Claude login.
  • Smaller guide fixes:
    • rig api --body takes inline JSON;
    • tool ids are real, and tools ls shows status and URL;
    • app new defaults --workspace to the current workspace, or to the one rig.yaml deploys to;
    • init --name is slugged;
    • rig login without a terminal points at RIG_API_KEY and --import-token.
  • CLI reference: the command pages are regenerated for the new flags and the workspace-mode commands. ssh-info no longer describes a line for another tool.

Before merging

  • Merge after rigbox-dev/cli#201 is released and jona62/rig-mvp#482 and jona62/rig-mvp#483 are deployed. These pages describe that behaviour.
  • The CLI reference was not produced by export_docs. It was rebuilt from the branch's --help output, with argument metadata carried over from the rc.2 export. It reproduced every unchanged page byte for byte first. scripts/generate-cli-reference.md records this.
  • Rerun the real export from the released CLI to replace it. The export also updates cli-reference/commands/ci/status.mdx, which still describes the old rig ci status.
  • generate-cli-reference.py --check, check-docs.py and build-navigation.py --check pass.

🤖 Generated with Claude Code

…I and SSH setup

The command pages now follow CLI revision 1880d04 (0.13.0-rc.4 plus the
unreleased fixes): `ssh add --name` is optional and sets up `ssh
<workspace>`, `rig api --body` takes inline JSON, `completions --no-rc`
needs `--install`, `ai defaults` shows the defaults with no flags, `tools
ls` shows status and URL, `init --name` is slugged, tool and template
examples name real ids, and every `--app` accepts a subdomain.

Workspace mode gains ai, api, config, completions, update, build and
volume, `--query` and the saved output default, and a `--workspace` that
defaults to the current workspace for metrics, ports, services, resize,
reconcile and app expose-port.

The export was reconstructed from that revision's `--help` output and
root help snapshots rather than `export_docs`, with argument metadata
carried over from the rc.2 export; it reproduced every unchanged command
byte for byte first. scripts/generate-cli-reference.md records this so
the next real export replaces it.

Curated notes say where each command runs: laptop-only commands, the
workspace lifecycle verbs, and setup-script/service-spec changes refuse
inside a workspace; deploy, logs --follow, ssh-info, update, and recipe
install describe their new behaviour.
rig login, rig ssh add and workspace spawn/start/restart/ssh-info now
register the local key (creating one when there is none), keep a Host
entry per workspace in ~/.config/rigbox/ssh_config included from
~/.ssh/config, and trust the gateway host keys in
~/.config/rigbox/known_hosts, so `ssh <workspace>` works from a terminal,
an editor or the Claude desktop app.

The SSH guide now leads with that setup and the alias, shows the managed
entry and ssh-info output (alias, full command, spawn link hint), and
covers `rig config set ssh-setup false`, the stopped-workspace message on
stderr, `ssh -t` with a command, SFTP/scp/rsync by alias, and that port,
agent and X11 forwarding are unavailable. The key, file transfer and
troubleshooting pages, the install guide, quickstart, workspace guide,
Spawn page and security boundaries follow suit. Legacy anchors are kept.
…kspaces too

rig update now downloads this platform's build from the public release
mirror, checks that it runs, and renames it over the binary that is
running (or into RIG_INSTALL_DIR), which also works for /usr/local/bin
inside a workspace. Document that, --version <tag>, the daily update
notice and RIGBOX_NO_UPDATE_CHECK, and the workspace's own update timer,
which also lifts a CLI below the supported minimum.
Inside a workspace the CLI now offers update, api, ai, config,
completions, build and volume alongside the app, deploy and workspace
commands, and answers the laptop-only commands (login, logout, api-key,
ssh, ci, release, rollback, uninstall), the workspace lifecycle verbs,
template deploy and setup-script/service-spec changes with one
`unsupported` line saying where they work.

The execution-modes page now lists both, with the refusal output, how
--workspace defaults to the current workspace, how rig deploy deploys
into the workspace it runs in and refuses clone, re-image and image
deploys, --output/--query and logs --follow there, and what the bridge
won't serve (account keys) or serves read-only (AI defaults, setup
scripts, service specs). The using-CLI, deploy, configuration, setup
script, service spec, app log and security pages point at it.
Anthropic clients (Claude Code, the Anthropic SDKs) add /v1/messages
themselves, so their base URL is the proxy root; OpenAI-compatible clients
take the /v1 base. Add a base-URL table, show the managed-mode hint that
`rig workspace ai mode` now prints with both (without -w inside a
workspace), and note that `rig ai defaults` with no flags shows the
defaults and only reads them inside a workspace.

`rig proxy on` exports RIGBOX_AI_PROXY_URL, OPENAI_BASE_URL and
OPENAI_API_KEY rather than OpenRouter variables, and `rig proxy off` only
unsets variables that still point at the proxy or hold its placeholder
key, leaving a user's own keys and endpoints set.
…ogins

`rig recipe app install --ref claude -w <ws>` adds a built-in coding agent
to a workspace that already exists (a bare catalog id or
@rigbox/<id>@Builtin, from the laptop or inside the workspace with its own
name), while `workspace spawn --catalog` covers new workspaces. List all
six built-in agents (claude, codex, opencode, kilocode, junie, pi) with
their routing.

The Claude Code item no longer overrides the user's own Claude setup: it
only merges hasCompletedOnboarding into ~/.claude.json, leaves
settings.json and permission prompts alone, and routes through the
workspace (proxy root as ANTHROPIC_BASE_URL) only while there is no
`claude` login, saved key, apiKeyHelper or Anthropic variable, with a
~/.config/rigbox/claude-own-auth opt-out.

The catalog guide also stops claiming that recipe install blocks until the
job completes or infers --workspace inside a VM, and its app start, stop
and rm examples pass --app.
- rig api --body takes inline JSON (or a file, or - for stdin) and prints
  a failed response verbatim with its status; the authentication page
  says so and the rename/custom-domain examples use inline bodies.
- Tool ids are architecture and virtual-browser; tools launch/install
  fail when the server did nothing, and tools ls shows STATUS and URL,
  which is where a launched tool's URL is read back.
- app new defaults --workspace to the current workspace, or on a laptop
  to the one this directory's rig.yaml deploys to. The expose-port
  example no longer wraps without --name, and the page explains the
  prompt and its refusal without a terminal.
- rig init --name is slugged into a name deploy accepts; ai defaults with
  no flags shows the defaults.
- rig login without a terminal names RIG_API_KEY and --import-token,
  reports only a rejected key as invalid, and sets up SSH access.
…restarts

A login that arrives while the platform restarts a service now waits up to about ten seconds for the workspace's keys instead of failing with Permission denied, so the troubleshooting pages point a persistent Permission denied at the key.
ssh-info no longer prints a line for another tool, so the sample output,
the Spawn page, and the command reference stop describing one.
@jona62
jona62 merged commit 98c826c into main Sep 30, 2026
2 checks passed
@jona62
jona62 deleted the docs/gap-report-ssh-vm branch September 30, 2026 01:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant