# Dockur Windows — Run Windows Inside a Docker Container > A Docker image that boots a full Windows installation inside a container using KVM acceleration, enabling automated testing, CI pipelines, and legacy app hosting without dedicated VMs. ## Install Save in your project root: # Dockur Windows — Run Windows Inside a Docker Container ## Quick Use ```bash docker run -it --rm -p 8006:8006 --device=/dev/kvm --cap-add NET_ADMIN -e VERSION="win11" dockurr/windows # Open http://localhost:8006 in your browser for the VNC console ``` ## Introduction Dockur Windows packages a fully automated Windows installer into a standard Docker image. It leverages KVM hardware virtualization to run Windows 11, 10, Server, or earlier editions at near-native speed inside a container. The project makes it possible to spin up disposable Windows environments for CI testing, browser automation, or legacy application hosting with a single `docker run` command. ## What Dockur Windows Does - Boots a real Windows installation inside a Docker container using QEMU/KVM - Supports Windows 11, 10, 8.1, 7, Vista, XP, Server 2022/2019/2016 and more - Automates the entire installation process including unattended setup - Exposes a browser-accessible VNC/noVNC interface on port 8006 - Allows custom ISO URLs, disk sizes, RAM allocation, and CPU counts via environment variables ## Architecture Overview The container runs a QEMU virtual machine with KVM pass-through for hardware acceleration. An entrypoint script handles downloading the Windows ISO (or using a user-supplied one), generating an unattended answer file, and launching the VM. Networking is bridged through Docker's network stack, and the VNC server exposes the display to the host browser. Persistent storage is supported via Docker volumes mapped to the virtual disk. ## Self-Hosting & Configuration - Requires a Linux host with KVM support enabled (`/dev/kvm` must be accessible) - Set `VERSION` environment variable to choose the Windows edition (e.g., `win11`, `win10`, `2022`) - Use `-v /path/to/storage:/storage` to persist the virtual disk across restarts - Configure RAM with `-e RAM_SIZE=8G` and CPU cores with `-e CPU_CORES=4` - Supply a custom ISO via `-e VERSION=/path/to/custom.iso` for enterprise images ## Key Features - Zero manual intervention: fully unattended Windows installation - Near-native performance via KVM hardware virtualization - Web-based VNC console accessible from any browser - Docker Compose support for reproducible multi-container setups - Lightweight wrapper with no proprietary dependencies ## Comparison with Similar Tools - **Virtual Box / VMware** — full desktop hypervisors with GUIs; Dockur is headless and container-native - **UTM (macOS)** — macOS-only QEMU frontend; Dockur runs on any Linux Docker host - **QEMU raw** — requires manual scripting; Dockur automates install and networking - **Firecracker** — micro-VM for Linux guests only; Dockur runs full Windows - **WSL2** — runs Linux on Windows; Dockur does the reverse, running Windows on Linux ## FAQ **Q: Does this require a Windows license?** A: Yes. The container downloads evaluation ISOs by default, but production use requires a valid license key passed via environment variable. **Q: Can I run this on a Mac or Windows host?** A: It requires a Linux host with KVM. Docker Desktop on macOS or Windows does not expose KVM, so a bare-metal or nested-virt Linux host is needed. **Q: How much disk space does the Windows VM need?** A: The default disk is 64 GB. You can adjust it with the `DISK_SIZE` environment variable. **Q: Is GPU pass-through supported?** A: Not currently. The VM uses a virtual GPU suitable for desktop and testing workloads. ## Sources - https://github.com/dockur/windows - https://hub.docker.com/r/dockurr/windows --- Source: https://tokrepo.com/en/workflows/asset-de40aa6c Author: AI Open Source