dockmaLightweight Docker on macOS,
free and open source.

Status: early development · Apple Silicon only · tested on macOS 27

$ curl -fsSL https://dockma.dev/install.sh | sh

Installs the latest release to ~/.local/bin, checksum-verified. Read the script before you run it.

Docker on a Mac, without the hassle.

dockma is a Docker runtime for Apple Silicon Macs, an alternative to running the engine through Docker Desktop, Colima or OrbStack. It boots a minimal Linux VM with Apple's Virtualization.framework and runs Docker Engine inside it. You keep using the docker CLI on your host: it talks to the engine through a Unix socket, and a launchd job keeps the VM running in the background.

It is in early development. Feel free to install it, daily-drive it and report issues, and read the known limitations first. If you need a battle-tested, production-ready alternative, consider Colima.

Features

Boots in ~1.0s

A custom-built 6.18 LTS kernel with only what Docker needs, and a busybox userspace.

Shared $HOME directory

Your home directory is shared via virtiofs at the identical path, so -v "$PWD:/src" just works.

Ports on localhost

-p 8080:80 is reachable at localhost:8080, IPv4 and IPv6. UDP (-p 1053:53/udp) and ports below 1024 work too. Gone when the container stops.

Containers reach the Mac

host.docker.internal and --add-host name:host-gateway resolve to your Mac, as on Docker Desktop.

amd64 images via Rosetta

--platform linux/amd64 runs x86-64 images through Rosetta for Linux.

dockma shell

A root shell in the VM through the guest agent, so it works even when dockerd doesn't.

Configurable

~/.dockma/daemon.json is merged over dockerd's config. Add registry mirrors, proxies and your own CA certificates.

VPNs, kind and k3s

The kernel has /dev/net/tun for Tailscale, and what kind, k3s and Docker-in-Docker need, network policies included.

A disk that gives space back

A sparse data disk that grows with dockma config --disk and is trimmed hourly, so data.img shrinks on the Mac.

Self-healing

Runs under launchd and restarts after a guest crash; a kernel panic reboots the guest in 5 s. dockma stop powers off cleanly.

Verified install

One install script, checked against the release's SHA256SUMS. dockma install fetches the matching guest image.

Free and open source

MIT licensed. The whole guest builds from one Dockerfile with make guest, so you can read and rebuild all of it.

A VM built for one job

The guest is not a general-purpose distribution. Everything in it exists to run Docker, and all of it is built from one Dockerfile.

  • Kernel: Linux 6.18.57, configured from tinyconfig with only what Docker needs. Everything is built in, with no modules.
  • Userspace: a busybox initramfs with Docker 29.9.1's static binaries. Its init keeps two services running: dockma-agent, a Go service on vsock, and dockerd.
  • Stateless root: the root filesystem is rebuilt on every boot. Only /var/lib/docker lives on the data disk.
  • Verifiable: kernel and Docker downloads are pinned and sha256-checked. Release builds carry provenance attestations.

Quick start

Install a release

# 1. Install the dockma CLI and its Linux guest from the latest release
curl -fsSL https://dockma.dev/install.sh | sh

# 2. Start the VM and point the docker CLI at it
dockma start
docker context use dockma
docker run --rm hello-world

Needs an Apple Silicon Mac with macOS 14 or later and the docker CLI (brew install docker). The script checks the download against the release's SHA256SUMS (and its build attestation, if gh is logged in), installs dockma to ~/.local/bin and fetches the matching Linux guest. Set DOCKMA_VERSION to pin a release or DOCKMA_INSTALL_DIR to install elsewhere. Optional: Rosetta for amd64 images. If DOCKER_HOST is set (Lima does this), it overrides the context.

From source

# 1. Build the guest kernel and initramfs (needs an existing arm64 Docker engine).
make guest
make install-guest            # copies vm/out/* to ~/.dockma/guest/

# 2. Build, sign and install the CLI to ~/.local/bin/dockma
make install

# 3. Start the VM
dockma start

# 4. Point the docker CLI at dockma
docker context use dockma     # created by `dockma start`
# or: export DOCKER_HOST=unix://$HOME/.dockma/docker.sock
docker run --rm hello-world

Also needs Xcode with Swift 6.4, and any arm64 Docker engine with buildx for the first guest build.

At a glance

$ dockma status
state:    running
docker:   ready (/Users/you/.dockma/docker.sock)
uptime:   12m 4s
vm:       6 CPUs, 4096 MiB, kernel 6.18.57
agent:    connected 0.7.2
ports:    8080, 1053/udp
daemon:   pid 55658 0.7.0

How it works

A lightweight daemon owns the VM and pipes the Docker, shell and port connections to a Go agent in the guest over vsock.

Full architecture →