vmrun-mcp
vmrun-mcp
MCP server that wraps VMware Workstation / Fusion / Player vmrun so
Claude Code, Cursor, OpenCode, FreeGrok/Grok Computer Hub, and other MCP
clients can power VMs, snapshots, guest copies, and screen captures on the
local desktop hypervisor (not vCenter/ESXi).
Requirements
Python 3.11+
vmrunonPATH(ships with VMware Workstation Pro / Fusion / Player)Linux, macOS, or Windows host where that product is installed
Install
git clone https://github.com/revytechinc/vmrun-mcp.git
cd vmrun-mcp
python3 -m venv .venv
. .venv/bin/activate
pip install -e .Smoke test:
vmrun list
python -m vmrun_mcp # waits on stdio — Ctrl-C; clients launch this for youEnvironment
Variable | Default | Meaning |
|
| Absolute path to |
|
|
|
| unset | Guest OS user for Tools guest ops |
| unset | Guest OS password |
| unset |
|
| common home dirs |
|
|
| Default for MCPs we make ( |
|
| Bind address for network transports |
|
| Bind port for network transports |
| unset | Must be |
Bind security (no auth)
This server does not implement authentication.
Default: Streamable HTTP on loopback:
python -m vmrun_mcp
# → http://127.0.0.1:8765/mcpFor spawn-only clients (many Claude/Cursor command entries):
VMRUN_MCP_TRANSPORT=stdio python -m vmrun_mcpSee examples/STREAMABLE-HTTP.md. Binding
0.0.0.0 or a LAN IP exits unless VMRUN_MCP_ALLOW_REMOTE=1 (warning still
printed). Do not expose this on a network without a reverse proxy and real auth.
Tools
Inventory (call these before changing boot media — never assume one disk):
list_registered_vms— discover.vmxunderVMRUN_VM_ROOTS/ common dirsdescribe_vm— every hard disk + CD/DVD, RAM, firmware, displayNameget_playbook— cold-start playbook (also resourcevmrun://playbook, promptinspect_before_boot; serverinstructionspoint here on connect)
Power: list_running_vms (running only), start_vm, stop_vm, reset_vm,
suspend_vm, pause_vm, unpause_vm
Snapshots: list_snapshots, snapshot, delete_snapshot, revert_to_snapshot
Guest / media: get_guest_ip, capture_screen, run_script_in_guest,
copy_file_host_to_guest, copy_file_guest_to_host, connect_named_device,
disconnect_named_device
Escape hatch: vmrun_raw
Client setup
Example snippets live in examples/. Restart the client after
editing config.
Cursor
User or project mcp.json (root key mcpServers):
{
"mcpServers": {
"vmrun": {
"command": "/absolute/path/to/vmrun-mcp/.venv/bin/python",
"args": ["-m", "vmrun_mcp"],
"env": {
"VMRUN_HOSTTYPE": "ws",
"VMRUN_ALLOWED_PREFIXES": "/home/you/vmware"
}
}
}
}Typical paths: ~/.cursor/mcp.json or <project>/.cursor/mcp.json.
Claude Code / Claude Desktop
~/.claude.json or project .mcp.json:
{
"mcpServers": {
"vmrun": {
"command": "/absolute/path/to/vmrun-mcp/.venv/bin/python",
"args": ["-m", "vmrun_mcp"],
"env": {
"VMRUN_HOSTTYPE": "ws"
}
}
}
}OpenCode
opencode.json / ~/.config/opencode/opencode.json — root key mcp,
command as a full array:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"vmrun": {
"type": "local",
"command": [
"/absolute/path/to/vmrun-mcp/.venv/bin/python",
"-m",
"vmrun_mcp"
],
"enabled": true,
"environment": {
"VMRUN_HOSTTYPE": "ws"
}
}
}
}(OpenCode v2 may nest under mcp.servers; use the shape your installed
OpenCode documents — both “flat mcp.<name>” and mcp.servers.<name> appear
in the wild.)
Grok / FreeGrok (xAI Computer Hub)
FreeGrok’s Computer Hub speaks MCP over stdio. Register the same command as a
local MCP server in the hub / agent config (name vmrun, command =
python -m vmrun_mcp from the venv). Tool results are MCP content blocks.
If a given Grok build only has shell tools, install the shared skill
vmware-workstation from revytechinc/skills
and call vmrun directly — same operations, no MCP required.
Pair with the skill
Agents should also load vmware-workstation from revytechinc/skills
(when to use ISO vs VMDK, UEFI, pulling images to ~/Desktop, safety). The MCP
is the control plane; the skill is the playbook.
License
BSD-2-Clause. Copyright (c) 2026 REVYTECH, Inc.