Nemeton MCP

官方

Nemeton 的開源 MCP 橋接工具:可從 Claude Desktop、Claude Code 或 Cursor 建立、啟動、製作快照及控制原生 macOS 虛擬機,包括客體系統內的 UI 自動化。在 Apple silicon 上本機執行。

你可以用 Nemeton MCP 做什麼?

  • 建立並設定 VM — 請你的助理建立一台 VM,指定發行版、CPU 數量和 RAM,之後再更新或複製它。
  • 控制 VM 電源狀態 — 啟動、停止、暫停、繼續、休眠或強制停止 VM,並檢查休眠狀態。
  • 透過 SSH 執行命令 — 使用 ssh_execute 在 VM 內執行命令,並用 vm_ip 找出它的位址。
  • 傳輸檔案 — 使用 file_upload、file_download 和 file_list 在 VM 內上傳、下載及列出檔案。
  • 管理快照 — 建立、列出、還原及刪除 VM 的 CoW 快照。
  • 讀取主控台與螢幕擷取畫面 — 傳送主控台輸入、讀取輸出、執行主控台命令,並擷取螢幕畫面。

文件

Nemeton MCP 伺服器

Swift Platform License MCP juergenkoller-software/nemeton-mcp MCP server

從 Claude Desktop、Claude Code、Cursor 或任何 MCP 用戶端控制原生 macOS 虛擬機。

這是 Nemeton 的官方 Model Context Protocol 橋接器 —— Nemeton 是一款原生 macOS 應用程式,使用 Apple 的 Virtualization.framework 來建立與管理 Linux 及 macOS 虛擬機(無需 Parallels、無需 VMware、無需訂閱)。

您需要安裝並執行 Nemeton 應用程式。 此 MCP 伺服器是一個精簡的 stdio→HTTP 橋接器 —— 實際的虛擬機邏輯位於應用程式內。請至 store.juergenkoller.software/apps/nemeton 取得 Nemeton。


您可以做什麼

「Claude,幫我開一台 Ubuntu 24.04 虛擬機,4 個 CPU、8 GB RAM,安裝 Docker,準備好時告訴我。」

此 MCP 伺服器在以下類別中提供 50 多種工具:

類別工具
虛擬機生命週期list_vms, get_vm, create_vm, update_vm, clone_vm, delete_vm, reorder_vms, stop_all
虛擬機控制start_vm, stop_vm, force_stop_vm, pause_vm, resume_vm, suspend_vm, get_suspend_status
快照(APFS 上的 CoW)list_snapshots, create_snapshot, restore_snapshot, delete_snapshot
主控台send_console, read_console, console_execute, take_screenshot
網路與檔案vm_ip, ssh_execute, file_upload, file_download, file_list
GUI 控制gui_launch, gui_windows, vscode_command, select_vm
剪貼簿橋接clipboard_read, clipboard_write
主機資訊get_host_info, get_metrics
儲存resize_disk, export_vm, import_vm
發行版list_distros(Ubuntu、Debian、Fedora、Arch —— 自動下載 ISO)
顯示fullscreen_enter, fullscreen_exit, fullscreen_toggle
Webhooklist_webhooks, register_webhook, delete_webhook
執行階段vm_runtime, vm_errors, list_downloads

每個工具都會傳回結構化 JSON,包含虛擬機狀態、快照中繼資料、主控台輸出或操作結果。


安裝

先決條件

  1. macOS 14(Sonoma)或更新版本 —— Virtualization.framework 功能所需。
  2. 已安裝並執行 Nemeton 應用程式 —— 在此取得。
  3. Swift 5.9+(Xcode 15+),如果您想從原始碼建置。也提供預先建置的二進位檔。

從原始碼建置

git clone https://github.com/juergenkoller-software/nemeton-mcp.git
cd nemeton-mcp
swift build -c release
# Binary: .build/release/NemetonMCP

預先建置的二進位檔

從 Releases 頁面 下載最新的 NemetonMCP 二進位檔。


設定

Claude Desktop

編輯 ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "nemeton": {
      "command": "/path/to/NemetonMCP",
      "env": {
        "NEMETON_PORT": "22100",
        "NEMETON_TOKEN": "your-token-here"
      }
    }
  }
}

從 Nemeton → Settings → API & Integrations 取得 NEMETON_TOKEN。

Claude Code

加入 ~/.claude/mcp.json(或透過 claude mcp add):

claude mcp add nemeton /path/to/NemetonMCP \
  --env NEMETON_PORT=22100 \
  --env NEMETON_TOKEN=your-token-here

Cursor / 其他 MCP 用戶端

模式相同:將 NemetonMCP 設定為 stdio MCP 伺服器,並使用上述兩個環境變數。


運作方式

┌────────────────┐  JSON-RPC stdio   ┌────────────────┐  HTTP+Bearer   ┌────────────────┐
│  Claude/Cursor │ ───────────────►  │  NemetonMCP    │ ─────────────► │  Nemeton.app   │
│  (MCP client)  │ ◄───────────────  │   (this repo)  │ ◄───────────── │  (port 22100)  │
└────────────────┘                   └────────────────┘                └────────────────┘

此橋接器從 stdin 讀取 JSON-RPC 2.0 請求,將其轉送至 Nemeton 位於 127.0.0.1:22100/mcp 的本機 HTTP 伺服器,並將回應寫回 stdout。所有驗證、虛擬機邏輯與工具分派都在 Nemeton 應用程式內進行。

這種拆分讓我們能將 MCP 傳輸格式保持開源(因此您可以稽核、分支,或透過您偏好的任何沙箱層執行),同時虛擬機內部機制仍保留在應用程式中。


環境變數

變數預設值說明
NEMETON_PORT22100Nemeton 本機 HTTP 伺服器的連接埠
NEMETON_TOKEN(無)來自 Nemeton Settings 的 Bearer 權杖(寫入操作所需)

錯誤與追蹤記錄會寫入 stderr,因此不會汙染 JSON-RPC 的 stdout 通道。


關於 Nemeton

Nemeton 是一款原生 macOS 應用程式,使用 Apple 的 Virtualization.framework 來建立與管理虛擬機。重點特色:

  • 無需訂閱 —— 一次性購買,€389
  • Linux 與 macOS 虛擬機,自動下載 ISO/IPSW
  • APFS 上的 CoW 快照 —— 儲存虛擬機狀態而不浪費磁碟空間
  • REST API + WebSocket 事件(42 個端點)供自動化使用
  • MCP 伺服器(此儲存庫)供 Claude/AI 代理使用
  • 原生效能 —— 直接使用 Apple 的框架,無 QEMU 額外負擔
  • 100% 本機 —— 無雲端、無遙測

→ 在 store.juergenkoller.software 取得 Nemeton


授權

MIT —— 請參閱 LICENSE。此橋接器為開源;Nemeton 應用程式本身為商業軟體。

問題與支援

由 Juergen Koller Software GmbH 打造。