Find a file
Bryan Helmkamp d426eebf1a Add sandbox MCP transport for running MCP servers inside Daytona sandboxes
Adds McpTransport::Sandbox variant that starts an MCP server inside the
sandbox, waits for it to listen, gets a Daytona preview URL, and rewrites
to HTTP transport for the MCP client connection.

Key changes:
- Sandbox trait: add get_preview_url(port) for authenticated port access
- DaytonaSandbox: implement get_preview_url via Daytona SDK preview links
- McpTransport::Sandbox: new variant with command, port, env fields
- Session: resolve_sandbox_mcp_servers() starts servers and rewrites to HTTP
- Integration test: end-to-end Playwright MCP in Daytona - navigates to
  example.com and verifies "Example Domain" in accessibility snapshot

Config example:
  [mcp_servers.playwright]
  type = "sandbox"
  command = ["npx", "@playwright/mcp@latest", "--port", "3100", "--headless"]
  port = 3100

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 02:09:04 -04:00
.cargo Disable empty doc-tests and add terse test output alias 2026-02-23 10:57:26 -05:00
.claude Update docs for arc cp, arc pr create, arc system df, worktree mode, and draft PR default 2026-03-10 00:45:26 -04:00
.config Fix Daytona e2e test failures and improve test reliability 2026-03-08 18:51:43 -04:00
.github Move packages/ to lib/packages/ and update all references 2026-03-09 13:13:56 -04:00
apps Move packages/ to lib/packages/ and update all references 2026-03-09 13:13:56 -04:00
arc/workflows Add hello workflow as a minimal hello world example 2026-03-09 19:29:01 -04:00
bin Organize scripts into bin/dev, bin/ops, and bin/agent 2026-03-09 13:07:22 -04:00
docker Move packages/ to lib/packages/ and update all references 2026-03-09 13:13:56 -04:00
docs Update docs for arc cp, arc pr create, arc system df, worktree mode, and draft PR default 2026-03-10 00:45:26 -04:00
lib Add sandbox MCP transport for running MCP servers inside Daytona sandboxes 2026-03-10 02:09:04 -04:00
test Rename arc run startarc run (#5) 2026-03-08 16:14:50 -04:00
.env.example Remove export prefix from .env.example for standard dotenv format 2026-03-09 23:46:44 -04:00
.gitignore Track .claude directory and add docs skill watermark 2026-03-08 11:23:07 -04:00
AGENTS.md Move packages/ to lib/packages/ and update all references 2026-03-09 13:13:56 -04:00
arc.toml Disable retros project-wide in arc.toml 2026-03-09 19:29:01 -04:00
bun.lock Move packages/ to lib/packages/ and update all references 2026-03-09 13:13:56 -04:00
Cargo.lock Add sandbox MCP transport for running MCP servers inside Daytona sandboxes 2026-03-10 02:09:04 -04:00
Cargo.toml Set default-members to arc-cli so bare cargo build skips server crates 2026-03-09 23:59:50 -04:00
CLAUDE.md Move CLAUDE.md to AGENTS.md with symlink for compatibility 2026-03-09 13:02:06 -04:00
package.json Move packages/ to lib/packages/ and update all references 2026-03-09 13:13:56 -04:00