This is a minimal template for using WSLg (Windows Subsystem for Linux GUI) with NVIDIA GPU on Docker Container (Ubuntu 20.04).
- Windows 11
- WSL2 (latest)
- Docker Desktop
- docker
- docker-compose V2
- GPU
docker compose up -d --build
docker compose exec gpu-wslg /bin/bash
You can use the following commands to test WSLg on Docker Container.
apt install -y x11-apps
xeyes
And you can use the following commands to test WSLg on Docker Container with GPU.
apt install -y mesa-utils
glxinfo -B
glxgears