Skip to content

docs(mocactl): define an sbx sandbox by what it is, with up as the common way in - #877

Merged
webchang merged 2 commits into
rossoctl:mainfrom
webchang:pr/i599-sbx-about
Nov 18, 2026
Merged

webchang merged 2 commits into
rossoctl:mainfrom
webchang:pr/i599-sbx-about

Conversation

@webchang

Copy link
Copy Markdown
Member

Refs #599. A follow-up to #871, from evaline-ju's review there (packages/mocactl/src/sbx/cli.ts:93), which came in after it merged.

What changed and why

  • The definition. SBX_ABOUT, printed before mocactl sbx --help and a bare mocactl sbx, defined a sandbox by the up workflow: "a copy of a local git repository on the sandbox service". A sandbox needs no repository: mocactl sbx create --template ID makes one, and run, put and proc use it by ID; only up, push and pull need git. It now opens with the sandbox itself, in the review's wording: "a workspace on the sandbox service, made from a template, where your coding agent's commands run in isolated VMs". Then comes up, "in a git repository", as the common way in, with the rest of the text as before (what up, push and pull copy, Bob's local tools, the lifetime). It ends with the way in without a repository: "mocactl sbx create --template ID makes one, and run, put and proc use it by ID".
  • The top-level line. mocactl --help's mocactl sbx … row said "a remote copy of a repository for your agent"; it now says "workspaces in isolated VMs for your agent".
  • The doc comment on SBX_ABOUT says the same.

Tests

  • packages/mocactl/test/sbx-cli.test.ts: the definition test checks the new opening, up "in a git repository", and the create --template ID sentence; the other assertions are unchanged.
  • packages/mocactl: tsc --noEmit is clean; the full suite passes (2098 passed, 4 skipped); prettier is clean.

Every commit is signed off (DCO).

Assisted-By: Claude Code

…mmon way in

Review follow-up to rossoctl#871 (evaline-ju): the help defined a sandbox by the
`up` workflow, as a copy of a local git repository, but a sandbox needs
no repository: `sbx create --template ID` makes one, and `run`, `put`
and `proc` use it by ID; only `up`, `push` and `pull` need git. The
definition now opens with the sandbox itself (a workspace on the sandbox
service, made from a template, where the agent's commands run in
isolated VMs), then `up` in a git repository, and ends with `create` for
use without one. The top-level `mocactl sbx …` line no longer says "a
remote copy of a repository". The help test follows the new wording.

Refs rossoctl#599

Assisted-By: Claude Code
Signed-off-by: Rong Chang <[email protected]>
@webchang
webchang requested a review from pdettori as a code owner November 18, 2026 00:18
@webchang webchang assigned pdettori and evaline-ju and unassigned pdettori Nov 18, 2026

@evaline-ju evaline-ju left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The sandbox is now defined independently of git, with up as the common way in. Two accuracy points on the new text: up can reuse a sandbox, and proc needs a lease+processes sandbox, which a default create isn't.

Comment thread packages/mocactl/src/sbx/cli.ts Outdated
(A bare \`mocactl\` session's tools run in a sandbox of moca's own server, SH_CONTROL_PLANE_URL:
these commands do not see it.)`;
export const SBX_ABOUT = `An sbx sandbox is a workspace on the sandbox service, made from a template, where your coding
agent's commands run in isolated VMs. In a git repository, \`mocactl sbx up\` creates one, copies

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

up creates or reuses the repo's sandbox (the SBX_USAGE line for up says "create or reuse its sandbox"). Suggest "creates or reuses one".

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in 4e00652: "mocactl sbx up creates or reuses one".

Comment thread packages/mocactl/src/sbx/cli.ts Outdated
in sync: \`mocactl sbx push\` sends later local edits, and \`mocactl sbx pull --apply\` applies the
agent's edits here as a patch. /workspace is kept between commands; the sandbox ends after a period
without use (7 days by default). Without a repository, \`mocactl sbx create --template ID\` makes
one, and \`run\`, \`put\` and \`proc\` use it by ID. (A bare \`mocactl\` session's tools run in a

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

create makes a per-exec sandbox by default, and proc is "lease+processes only", so proc doesn't work by ID on a default create. Either drop proc here or mention --mode lease+processes. Also, --template is optional (the default template is used), so mocactl sbx create alone reads more accurately.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in 4e00652: it now reads "mocactl sbx create makes one (from the default template, or --template ID), and run and put use it by ID; proc needs one made with --mode lease+processes".

…cesses

Review follow-up (evaline-ju): `up` creates or reuses the repository's
sandbox, as its usage line says; and a default `create` is per-exec,
where `proc` doesn't work, so the definition now says `run` and `put`
use it by ID and `proc` needs one made with `--mode lease+processes`.
`--template` is optional, so it reads `mocactl sbx create` (the default
template, or `--template ID`).

Refs rossoctl#599

Assisted-By: Claude Code
Signed-off-by: Rong Chang <[email protected]>
@webchang
webchang merged commit 6db4171 into rossoctl:main Nov 18, 2026
17 checks passed
@pdettori pdettori added this to the v0.11.0 milestone Nov 19, 2026
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.

3 participants