Requirements
| Requirement | Details |
|---|---|
| Hardware | Apple Silicon Mac, M1 or later (tested on M4). |
| macOS | A version QEMU supports: the current one and, for up to two years, the previous one (tested on macOS 15). |
| Runtime | QEMU from Homebrew. The installer handles it, installing Homebrew too if needed. |
| Memory | 4 GB per running Ubuntu VM, 8 GB per running Windows VM. |
| Disk | ~10 GB per Ubuntu image, ~30 GB per Windows image, each including its snapshot. |
Install
curl -fsSL https://agentpc.pawanpaudel.com.np/install.sh | sh
The installer:
- downloads the latest release and verifies its checksum,
- installs
agentpcto~/.local/bin(nosudo) and adds it to yourPATH, - installs QEMU with Homebrew if it's missing (installing Homebrew first if needed, which asks for your password once),
- registers the MCP server with the agents it finds,
- checks everything with
agentpc doctor.
Upgrade later with agentpc update. Installer options:
| Variable | Effect |
|---|---|
AGENTPC_VERSION=0.1.0 | Install a specific version. |
AGENTPC_INSTALL_DIR=<dir> | Install somewhere other than ~/.local/bin. |
AGENTPC_NO_MCP=1 | Skip registering the MCP server. |
Images
Every VM is a copy-on-write clone of a read-only image, so it starts from a clean
install and costs only a few MB. A bare ubuntu means
ubuntu-24.04, and a bare windows
means windows-11-25h2. Pin the full name when the release
matters, for example in test harnesses.
| Image | Source and how to get it |
|---|---|
ubuntu = ubuntu-24.04 |
Official Ubuntu 24.04 cloud image. image pull (automatic on first create) or image build. |
ubuntu-<release> |
Any release on cloud-images.ubuntu.com, e.g. 22.04 or 26.04. image build ubuntu-22.04, or image pull if published. |
windows-11-25h2 |
Windows 11 25H2 (Home/Pro), 7.3 GB ISO from Microsoft. image build windows. |
windows-11-24h2, windows-11-23h2 |
Earlier Windows 11 releases. image build windows-11-23h2. |
windows-<name> |
Your own Windows 11 ARM64 Home/Pro ISO. image build windows-<name> --iso <path>. |
Only ARM64 Windows runs at native speed on Apple Silicon, and Windows 10's ARM64 build hangs at boot, so Windows 11 is the minimum. Enterprise, LTSC and evaluation ISOs aren't supported. Windows runs unactivated (a watermark, nothing else).
Images are clean installs, like a customer's new PC: Windows has no Visual C++
redistributable, no .NET beyond the built-in Framework 4.8.1, and no PowerShell 7. If a
program fails with a missing VCRUNTIME140.dll, its installer is
missing a dependency. Each image records what it is:
$ agentpc image info windows
{
"os": "windows",
"version": "Windows 11 Pro 25H2 (build 26200.6584)",
"arch": "arm64",
"built": "20260927",
"desktop_server": "cua-driver 0.30.1",
…
}
How it works
- Hypervisor. VMs run in QEMU on Apple's Hypervisor.framework, natively on Apple Silicon.
- Instant start. After building or downloading an image, agentpc boots it once, waits until the desktop and its control server are running, and saves the VM's memory. New VMs resume from that state instead of booting: ~1 s / ~4 s instead of ~14 s / ~25 s.
- Checkpoints. A checkpoint pauses the VM for a few seconds, writes its memory to a file and clones its disk with an APFS copy-on-write clone.
- Snapshots stay local. A memory snapshot depends on the Mac's chip and QEMU version, so only the disk is published; the snapshot is recaptured after each pull (about a minute).
- Image distribution. Ubuntu images are OCI artifacts on GitHub Container Registry: a compressed qcow2 split into 64 MB parts, downloaded in parallel and checksum-verified.
- Agent-ready guests. Each snapshot capture turns off what interrupts unattended work (SmartScreen, updates, first-run pop-ups, Ubuntu's background apt jobs) and installs Chrome on Ubuntu.
Networking
Each VM sits behind QEMU's user-mode NAT: VMs are isolated from each other but share the Mac's network, so a VPN on the Mac applies to their outbound traffic.
| To reach | Do this |
|---|---|
| A VM server from the Mac | agentpc forward <name> <guest-port> (MCP: forward_port), then connect to 127.0.0.1:<host-port>. Works for servers bound to the guest's own 127.0.0.1; the Windows firewall doesn't apply. |
| The Mac from a VM | 10.0.2.2 is the Mac. A dev server on 127.0.0.1 or 0.0.0.0 is at 10.0.2.2:<port>. |
| VM to VM | Forward VM B's port to the Mac, then from VM A connect to 10.0.2.2:<host-port>. |
| Through a corporate proxy | Guests inherit no proxy. Set HTTP_PROXY/HTTPS_PROXY in the guest and import your root CA (Import-Certificate or update-ca-certificates). |
Offline VMs (--offline / offline: true)
can't reach the internet or 10.0.2.2, but ports you forward from
the Mac still reach them.
Configuration
| Variable | Description |
|---|---|
AGENTPC_HOME | Where images, VMs, keys and caches live. Default ~/.agentpc. |
AGENTPC_IMAGE_REPO | Package for image pull/push. Default ghcr.io/pawanpaudel93/agentpc. |
WIN_ISO | Windows ISO used by image build windows-… without --iso. |
AGENTPC_KEEP_RUNNING | Set to 1 to keep VMs running when an MCP session ends. |
Each VM gets its own ports on 127.0.0.1, derived from its slot number n:
| Port | Use |
|---|---|
47000 + n | SSH |
47100 + n | Windows-MCP (Windows images built by 0.1.0) |
47200 + n | noVNC WebSocket, for the viewer |
47300 + n | VNC |
8100 | Browser viewer, shared by all VMs |
Windows guest tips
GUI installers return immediately
Run them silently and wait for the process, then check its exit code:
Start-Process installer.exe -ArgumentList '/S' -Wait -PassThru
Windows Update is disabled
So updates never interrupt a task. This also blocks DISM /online
and Add-WindowsCapability. Re-enable it temporarily:
Set-Service wuauserv -StartupType Manual; Start-Service wuauserv
# … Add-WindowsCapability / DISM …
Stop-Service wuauserv; Set-Service wuauserv -StartupType Disabled
Defender is on
Only SmartScreen is off. Defender may quarantine a fresh or unsigned test binary, so exclude your work directory:
Add-MpPreference -ExclusionPath C:\work
Hardware limits
Guests have a fixed 1280×800 display, a 2D-only GPU (no 3D acceleration; WebGL is software-rendered or unavailable) and no audio device.
Troubleshooting
| Symptom | Try |
|---|---|
| Something's off with the setup | agentpc doctor |
| Can't tell what the VM is doing | agentpc screenshot <name>, or open the viewer URL from agentpc info <name>. |
| VM won't boot | Read qemu.log and serial.log in ~/.agentpc/instances/<name>/ (MCP: read_vm_log). |
| VM is in a bad state | agentpc reset <name> |
| SSH dropped after a reboot | agentpc start <name> waits until the desktop is ready again. |
image build/pull/rm refuses | VMs still use that image; agentpc rm them first. |
| Running low on disk | agentpc clean deletes what can be downloaded again. |
Security
- Everything listens on
127.0.0.1only. - The desktop-control servers inside VMs are unauthenticated; any process on your Mac can reach them.
- Each VM has its own VNC password. The viewer URL from
agentpc infocarries it, so the browser viewer connects without a prompt. - Guests use the fixed login
agent/agent. Windows VMs have UAC prompts, SmartScreen and Windows Update turned off. - VMs can reach the internet and your Mac through
10.0.2.2. Use--offlinefor untrusted software. - Treat VMs as throwaway sandboxes, not a place for secrets.
Uninstall
$ agentpc uninstall # asks first; -y skips the prompt
This stops all VMs, removes the MCP server from every agent, and deletes
~/.agentpc (--keep-data keeps it) and the
binary. It leaves shared things alone and lists them: the PATH line,
QEMU, and the Claude plugin.