跳到主要内容

Claude Cage · 面向 Claude 的隔离开发环境,支持桌面工作台、多账号、远程部署与移动端连接。上游 Lee-xeo/Claude-Cage 完整源码镜像,非灵栈原创;主许可 MIT,第三方组件遵循各自许可。来源:https://github.com/Lee-xeo/Claude-Cage 。手动同步,不附带 Release 安装包。

提交记录

feat: add native support for Mistral Vibe

Add Mistral Vibe as a first-class agent alongside claude, opencode and codex: - install the `vibe` CLI in the base VM during setup - pre-configure the Chrome DevTools MCP server in ~/.vibe/config.toml - add `agent-vm vibe` command, running with `--agent auto-approve` for full autonomy inside the sandbox (and a tty, since Vibe is a full-screen TUI) - document the new agent in the help text and README Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

作者
benoitvx
时间
2026/06/10 16:44
提交
ddde4b3
上一个
d2b1270
这个版本的全部文件
修改README.md+4 −1看文件
@@ -4,7 +4,7 @@ Run AI coding agents inside sandboxed Linux VMs. The agent gets full autonomy wh
44
55Uses [Lima](https://lima-vm.io/) to create lightweight Debian VMs on macOS and Linux. Ships with dev tools, Docker, and a headless Chrome browser with [Chrome DevTools MCP](https://github.com/ChromeDevTools/chrome-devtools-mcp) pre-configured.
66
7删除:Supports [Claude Code](https://claude.ai/code), [OpenCode](https://github.com/anomalyco/opencode), and [Codex CLI](https://github.com/openai/codex) out of the box. Other agents can be run via `agent-vm shell`.
7新增:Supports [Claude Code](https://claude.ai/code), [OpenCode](https://github.com/anomalyco/opencode), [Codex CLI](https://github.com/openai/codex), and [Mistral Vibe](https://docs.mistral.ai/vibe/code/cli/install-setup) out of the box. Other agents can be run via `agent-vm shell`.
88
99Never install attack vectors such as npm, claude or even Docker on your host machine again!
1010
@@ -56,6 +56,7 @@ cd your-project
5656agent-vm claude # Claude Code
5757agent-vm opencode # OpenCode
5858agent-vm codex # Codex CLI
59新增:agent-vm vibe # Mistral Vibe
5960```
6061
6162Creates a persistent VM for the current directory (or reuses it if one already exists), mounts your working directory, and runs the agent with full permissions. The VM persists after the agent exits so you can reconnect later. Ports opened inside the VM (e.g. by Docker containers or dev servers) are automatically forwarded to your host by Lima.
@@ -64,6 +65,7 @@ Each agent runs with its respective auto-approve flag:
6465- `claude` runs with `--dangerously-skip-permissions`
6566- `opencode` does not yet have an auto-approve flag (waiting on [this PR](https://github.com/anomalyco/opencode/pull/11833))
6667- `codex` runs with `--dangerously-bypass-approvals-and-sandbox`
68新增:- `vibe` runs with `--agent auto-approve`
6769
6870Any extra arguments are forwarded to the agent command:
6971
@@ -72,6 +74,7 @@ agent-vm claude -p "fix all lint errors" # Run with a prompt
7274agent-vm claude --resume # Resume previous session
7375agent-vm opencode -p "refactor auth module" # OpenCode with a prompt
7476agent-vm codex -q "explain this codebase" # Codex with a query
77新增:agent-vm vibe -p "fix all lint errors" # Mistral Vibe with a prompt
7578```
7679
7780### Shell access and running commands
修改agent-vm.setup.sh+23 −0看文件
@@ -85,6 +85,11 @@ echo 'export PATH=$HOME/.local/bin:$HOME/.claude/local/bin:$HOME/.opencode/bin:$
8585echo "Installing Codex CLI..."
8686sudo npm i -g @openai/codex
8787
88新增:# Install Mistral Vibe (installs uv and the `vibe`/`vibe-acp` commands into ~/.local/bin,
89新增:# which is already on PATH via the lines added above)
90新增:echo "Installing Mistral Vibe..."
91新增:curl -LsSf https://mistral.ai/vibe/install.sh | bash
92新增:
8893# Configure Chrome DevTools MCP server for Claude
8994echo "Configuring Chrome MCP server for Claude..."
9095CONFIG="$HOME/.claude.json"
@@ -132,4 +137,22 @@ else
132137JSON
133138fi
134139
140新增:# Configure Chrome DevTools MCP server for Vibe
141新增:# Vibe uses TOML; append an array-of-tables entry (valid even if the wizard later
142新增:# writes to the same file). Guard against duplicates on repeated setup runs.
143新增:echo "Configuring Chrome MCP server for Vibe..."
144新增:VIBE_CONFIG_DIR="$HOME/.vibe"
145新增:mkdir -p "$VIBE_CONFIG_DIR"
146新增:VIBE_CONFIG="$VIBE_CONFIG_DIR/config.toml"
147新增:if ! grep -q 'name = "chrome-devtools"' "$VIBE_CONFIG" 2>/dev/null; then
148新增: cat >> "$VIBE_CONFIG" << 'TOML'
149新增:
150新增:[[mcp_servers]]
151新增:name = "chrome-devtools"
152新增:transport = "stdio"
153新增:command = "npx"
154新增:args = ["-y", "chrome-devtools-mcp@latest", "--headless=true", "--isolated=true"]
155新增:TOML
156新增:fi
157新增:
135158echo "VM setup complete."
修改agent-vm.sh+42 −2看文件
@@ -11,6 +11,7 @@
1111# agent-vm claude - Run Claude Code in a persistent VM for cwd
1212# agent-vm opencode - Run OpenCode in a persistent VM for cwd
1313# agent-vm codex - Run Codex CLI in a persistent VM for cwd
14新增:# agent-vm vibe - Run Mistral Vibe in a persistent VM for cwd
1415# agent-vm shell - Open a shell in the persistent VM for cwd
1516# agent-vm stop - Stop the VM for cwd
1617# agent-vm rm - Stop and delete the VM for cwd
@@ -255,6 +256,9 @@ agent-vm() {
255256 codex)
256257 _agent_vm_codex "${vm_opts[@]}" "$@"
257258 ;;
259新增: vibe)
260新增: _agent_vm_vibe "${vm_opts[@]}" "$@"
261新增: ;;
258262 shell)
259263 _agent_vm_shell "${vm_opts[@]}" "$@"
260264 ;;
@@ -296,6 +300,7 @@ Commands:
296300 claude [args] Run Claude Code in the VM for the current directory
297301 opencode [args] Run OpenCode in the VM for the current directory
298302 codex [args] Run Codex CLI in the VM for the current directory
303新增: vibe [args] Run Mistral Vibe in the VM for the current directory
299304 shell Open a shell in the VM for the current directory
300305 run <cmd> [args] Run a command in the VM for the current directory
301306 stop Stop the VM for the current directory
@@ -305,7 +310,7 @@ Commands:
305310 status Show status of all VMs (current dir marked with >)
306311 help Show this help
307312
308删除:VM options (for claude, opencode, codex, shell, run):
313新增:VM options (for claude, opencode, codex, vibe, shell, run):
309314 --disk GB VM disk size (default: 10)
310315 --memory GB VM memory (default: 2)
311316 --cpus N Number of CPUs (default: 1)
@@ -320,6 +325,7 @@ Examples:
320325 agent-vm claude # Run Claude in a VM
321326 agent-vm opencode # Run OpenCode in a VM
322327 agent-vm codex # Run Codex in a VM
328新增: agent-vm vibe # Run Mistral Vibe in a VM
323329 agent-vm --disk 50 --memory 16 --cpus 8 claude # Custom resources
324330 agent-vm --reset claude # Fresh VM from base template
325331 agent-vm --rm claude # Destroy VM after Claude exits
@@ -441,7 +447,7 @@ _agent_vm_setup() {
441447 date +%s > "$AGENT_VM_STATE_DIR/.agent-vm-base-version"
442448
443449 echo ""
444删除: echo "Base VM ready. Run 'agent-vm shell', 'agent-vm claude', 'agent-vm opencode', or 'agent-vm codex' in any project directory."
450新增: echo "Base VM ready. Run 'agent-vm shell', 'agent-vm claude', 'agent-vm opencode', 'agent-vm codex', or 'agent-vm vibe' in any project directory."
445451 echo "Note: Existing VMs were not updated. Use --reset to re-clone them from the new base."
446452}
447453
@@ -543,6 +549,40 @@ _agent_vm_codex() {
543549 return $exit_code
544550}
545551
552新增:_agent_vm_vibe() {
553新增: local vm_opts=()
554新增: local args=()
555新增: local rm=""
556新增: while [[ $# -gt 0 ]]; do
557新增: case "$1" in
558新增: --disk) vm_opts+=(--disk "$2"); shift 2 ;;
559新增: --memory|--ram) vm_opts+=(--memory "$2"); shift 2 ;;
560新增: --cpus) vm_opts+=(--cpus "$2"); shift 2 ;;
561新增: --reset) vm_opts+=(--reset); shift ;;
562新增: --offline) vm_opts+=(--offline); shift ;;
563新增: --readonly) vm_opts+=(--readonly); shift ;;
564新增: --git-read-only|--git-ro) vm_opts+=(--git-read-only); shift ;;
565新增: --rm) rm=1; shift ;;
566新增: *) args+=("$1"); shift ;;
567新增: esac
568新增: done
569新增: local host_dir
570新增: host_dir="$(pwd)"
571新增: local vm_name
572新增: vm_name="$(_agent_vm_name "$host_dir")"
573新增:
574新增: _agent_vm_ensure_running "$vm_name" "$host_dir" "${vm_opts[@]}" || return 1
575新增: _agent_vm_print_resources "$vm_name"
576新增:
577新增: # Vibe is a full-screen TUI, so allocate a tty (like opencode).
578新增: # --agent auto-approve gives full autonomy (safe inside the sandbox).
579新增: local exit_code=0
580新增: limactl shell --tty --workdir "$host_dir" "$vm_name" vibe --agent auto-approve "${args[@]}"
581新增: exit_code=$?
582新增: [[ -n "$rm" ]] && { echo "Removing VM..."; _agent_vm_destroy; }
583新增: return $exit_code
584新增:}
585新增:
546586_agent_vm_shell() {
547587 local vm_opts=()
548588 local rm=""