Configs2026年5月19日·1 分钟阅读

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.

Agent 就绪

这个资产可以被 Agent 直接读取和安装

TokRepo 同时提供通用 CLI 命令、安装契约、metadata JSON、按适配器生成的安装计划和原始内容链接,方便 Agent 判断适配度、风险和下一步动作。

Native · 98/100策略:允许
Agent 入口
任意 MCP/CLI Agent
类型
Skill
安装
Single
信任
信任等级:Established
入口
Dockur Windows
通用 CLI 安装命令
npx tokrepo install de40aa6c-539e-11f1-9bc6-00163e2b0d79

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

讨论

登录后参与讨论。
还没有评论,来写第一条吧。

相关资产