Repository navigation
Description
Context
A Windows machine can join a pool and ask for lanes, but it cannot run lanes for others (pool.md: "a Windows machine asks for lanes but does not run them yet"). On Windows the share switch only reports capacity: no node agent runs, the machine reports no API, and the coordinator refuses it ("runs no node agent"). Other members never see it as a place to start.
A lane runs as a Linux container, with a static Linux devstack mounted into it (ADR-0028 point 2). The agent provides that binary only when it is a Linux build itself (linux_binary() in crates/devstack-node/src/node.rs). On Linux, the agent, Docker and the lanes share one kernel: the agent's paths are Docker's paths, its iptables are the bridges' iptables, /proc is the machine.
Direction (owner, 2026-10-21): real Docker-in-Docker. The Windows devstack starts one privileged Linux container (e.g. docker:dind) in Docker Desktop. That container holds its own Docker daemon, the node agent (the static Linux release binary of the same version) and every guest lane. The alternative was the agent beside Docker Desktop with the host's Docker socket (the existing "agent in a container" mode). Docker-in-Docker was preferred for two reasons:
- A hard cap:
--cpus/--memoryon the one container bound all guest lanes together. That matters on a machine someone works at. - Separation: own image cache and disk (one volume, removable at once), and no access to the user's own containers.
This issue collects what to decide. An ADR follows (it extends ADR-0025 and ADR-0033; ADR-0011 is about Windows-native), then the code.
To decide
- Identity in the pool. The container needs its own membership, or it shares the Windows machine's.
- Own membership: it joins once and an admin grants it as a node, so the machine appears twice. Needs a link ("node of ") in the pool view and in placement.
- Shared membership: one member, two reporters (the hub and the agent). The coordinator would have to merge their reports.
- Lifecycle and UI.
- Who starts and stops the container: the share switch on Windows, or
devstack node host on|off, or both? - What happens when Docker Desktop is not running? Autostart with
--restart unless-stopped? - Updates: the same version as the Windows
devstack, swapped when it updates. Lanes running at that moment are drained or stopped.
- Who starts and stops the container: the share switch on Windows, or
- Image and binary.
- Base: a stock
docker:dindwith the static musldevstackmounted from the Windows install (downloaded from the release, checked againstSHA256SUMS), or our own image on ghcr? - Pinning: by version and digest.
- Base: a stock
- Capacity.
- Inside the container
/procshows the WSL2 VM, not Windows. - Who computes "half of what is free": the Windows hub, which knows the real values, passing them in?
- How caps from the share settings become
--cpus/--memory, and what happens when they change: a restart of the container, ordocker update.
- Inside the container
- Network.
- The agent's port (4261) published to the Windows host, plus a Windows firewall rule. Who creates the rule: does it need elevation once?
--apiaddress: the LAN IP changes on a laptop. Report it fresh, or use a hostname?- Egress rules (ADR-0033): iptables of the inner daemon, inside the DinD container. Verify that guest traffic is filtered and that the user's LAN and the Windows host stay unreachable unless allowed.
- Security.
--privilegedis needed for DinD. An escape lands in Docker Desktop's VM (not in Windows directly), but that VM also runs the user's own containers.- Is that acceptable for a developer machine?
- Rootless DinD or Sysbox as alternatives?
- Storage.
- Inner
/var/lib/dockeron a named volume, so images and kept lanes survive a restart. - Disk cap and pruning (
keep_lanes_gib, ADR-0038). - The WSL2
ext4.vhdxgrows and does not shrink by itself.
- Inner
- Availability.
- A laptop sleeps and Docker Desktop may be off, so such a node is never
--dedicated. - What happens to leases on sleep: the lane's data outlives its lease (ADR-0038).
- A laptop sleeps and Docker Desktop may be off, so such a node is never
- GPU. Docker Desktop passes NVIDIA GPUs through WSL2 (
--gpus). The inner daemon needs the NVIDIA container toolkit. Supported from the start, or later? - Transparency. Guest lanes are invisible in Docker Desktop's UI (they run in the inner daemon). The dashboard shows them (guest lanes, feat(pool): show lanes of other members that run on this machine #167). Is that enough?
Spike before the ADR
On one Windows 11 machine with Docker Desktop (WSL2), by hand:
docker:dindwith caps.- The static
devstackin it,devstack join, an admin grants it as a node. - A lane started from another member.
Check:
- the egress rules,
- the firewall,
- the reported capacity,
- a restart of Docker Desktop and of the machine,
- disk use.
Meanwhile
On Windows the share switch is disabled and says why (#169). Today it reports capacity that nobody can use.
Activity
feat(pool)!: remove the share switch; the hub offers the pool nothing
feat(pool)!: remove the share switch; the hub offers the pool nothing (…
spike(#168): caps below WSL's memory, Docker Desktop after wsl --shut…
spike(#168): join inside the distribution, not on Windows
spike(#168): put ~/.local/bin on PATH in the distribution
spike(#168): the smoke lane from a repository of its own; caps of 8 GiB
7schmiede commentedon Nov 18, 2026
Spike result: a Windows machine's GPU as a pool node, through WSL2
Branch
spike/168-wsl-gpu-node(runbook,check.sh, a smoke stack). Not Docker-in-Docker: the released Linux node agent in a WSL2 distribution.Setup: Windows 11, WSL 2.6, an NVIDIA RTX 5070 Ti (16 GiB). A distribution of its own (Ubuntu 24.04) with Docker Engine and the NVIDIA Container Toolkit (Docker Desktop's WSL integration off for it),
networkingMode=mirrored, a Hyper-V firewall rule for 4261, devstack 0.49.4.check.sh: 0 FAIL.Result:
devstack.node.gpus = 1).devstack up --on <pool>:<node>: lease, sync and start within seconds; the Compose service with annvidiareservation printednvidia-smi's table with the GPU. Other members reach the agent's port through mirrored networking and the Hyper-V rule.Learned on the way:
devstack joinrun in PowerShell instead of the distribution finds the machine's existing membership and answers "joined" at once, with no new request.wsl --shutdown(after changing.wslconfig) ends Docker Desktop too..wslconfig'smemory=caps the whole distribution: the agent's--max-memory-gibbelongs below it.install.shputs devstack in~/.local/bin, not onPATHin a root shellwsl -dopens.For this issue's questions:
--privilegedcontainer, but a distribution with its own engine.7schmiede commentedon Nov 18, 2026
Released in 0.50.0: the share switch runs the node agent in a WSL2 distribution on Windows (ADR-0113, #580), the way of this issue's spike rather than Docker-in-Docker; GPUs per lane (ADR-0112, ADR-0114). Left open until the switch has run on a real Windows machine with WSL (the spike's machine is next); then this closes with what that showed.