Skip to content

feat(local): warn users before executing commands on their machine#3433

Open
aulorbe wants to merge 1 commit into
mainfrom
local-spawn-warning
Open

feat(local): warn users before executing commands on their machine#3433
aulorbe wants to merge 1 commit into
mainfrom
local-spawn-warning

Conversation

@aulorbe
Copy link
Copy Markdown
Collaborator

@aulorbe aulorbe commented May 21, 2026

Summary

  • Replaces the openclaw-only local installation warning with a universal warning that applies to all agents spawned locally
  • Presents users with a 3-option selector before proceeding:
    • Ok — execute directly on this machine (no change in behavior)
    • Sandbox — inject --beta sandbox so the agent runs inside a Docker container instead of on the host
    • Cancel — abort the operation
  • Warning is skipped when sandbox mode is already active or in non-interactive/headless mode (SPAWN_NON_INTERACTIVE=1)
  • When "Sandbox" is selected, SPAWN_BETA env var is updated before agent/runner resolution so the Docker-wrapped runner is used correctly

Test plan

  • biome lint — 203 files, 0 issues
  • biome check — formatting clean
  • Build compiles without errors
  • 97 orchestrate/sandbox tests pass
  • Manual: spawn <agent> local shows warning with Ok/Sandbox/Cancel
  • Manual: selecting Ok proceeds normally
  • Manual: selecting Sandbox enables Docker container mode
  • Manual: selecting Cancel exits cleanly
  • Manual: --beta sandbox skips the warning entirely
  • Manual: headless/non-interactive mode skips the warning

Copy link
Copy Markdown
Collaborator Author

aulorbe commented May 21, 2026

This stack of pull requests is managed by Graphite. Learn more about stacking.

@aulorbe aulorbe marked this pull request as ready for review May 21, 2026 06:09
Local spawns now show a security warning with three options: Ok (proceed
normally), Sandbox (run inside a Docker container), or Cancel (abort).
Replaces the previous openclaw-only warning with a universal prompt that
applies to all agents. When Sandbox is selected, the function re-invokes
with useSandbox=true so the Docker-wrapped runner is used.
@aulorbe aulorbe force-pushed the local-spawn-warning branch from 42a6fdf to 65119aa Compare May 21, 2026 06:38
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.

2 participants