clone of my dotfiles.ssp.sh
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

documentation

sspaeti 4275d4b3 aeae1852

+85 -3
+82
hypr/.config/hypr/sspaeti/windows-ms/README.md
··· 1 + # Windows VM Integration 2 + 3 + A seamless Windows 11 VM setup that integrates with your Linux desktop environment via Docker and RDP. 4 + 5 + > **First-time startup will take significantly longer** as the container needs to: 6 + > - Download the Windows 11 ISO (~5GB) 7 + > - Install and configure Windows 8 + > - This can take 30-60 minutes depending on your internet connection 9 + 10 + After the initial setup, subsequent launches will be much faster (2-3 minutes). See [dockur/windows](https://github.com/dockur/windows) for more details on the setup process. 11 + 12 + ## Files 13 + 14 + - `docker-compose.yml` - Docker Compose configuration for Windows 11 VM 15 + - `start-windows.sh` - Automated launch script with lifecycle management 16 + - `../../../linux_applications/.local/share/applications/windows-vm.desktop` - Desktop entry for application launcher 17 + 18 + ## How It Works 19 + 20 + ### Launch Process 21 + 1. **Desktop Integration**: Appears as "Windows VM" in your application launcher 22 + 2. **Container Management**: Starts Docker container with Windows 11 23 + 3. **Health Monitoring**: Waits for container to be running and web interface to respond 24 + 4. **RDP Connection**: Automatically opens RDP connection (1920x1200 resolution) 25 + 5. **Auto-Cleanup**: When you close RDP, the Windows VM automatically shuts down 26 + 27 + ### Configuration 28 + - **OS**: Windows 11 29 + - **Resources**: 8GB RAM, 4 CPU cores 30 + - **Acceleration**: KVM support for better performance 31 + - **Storage**: Persistent storage mounted to `~/windows` 32 + - **Network**: 33 + - RDP: `127.0.0.1:3389` 34 + - Web Interface: `http://127.0.0.1:8006` 35 + 36 + ### Key Features 37 + - **Smart Waiting**: Monitors Docker container health and web interface before launching RDP 38 + - **Signal Handling**: Properly handles interruptions with cleanup 39 + - **UWSM Integration**: Runs as a managed Hyprland application 40 + - **One-Click Experience**: Single click to boot Windows and connect 41 + - **Automatic Shutdown**: VM stops when RDP session ends 42 + 43 + ## Usage 44 + 45 + ### Via Desktop Launcher 46 + Simply click "Windows VM" from your application launcher. 47 + 48 + ### Via Command Line 49 + ```bash 50 + ./start-windows.sh 51 + ``` 52 + 53 + ### Manual Docker Management 54 + ```bash 55 + # Start container 56 + docker-compose up -d 57 + 58 + # Stop container 59 + docker-compose down 60 + 61 + # View logs 62 + docker-compose logs -f 63 + ``` 64 + 65 + ## Requirements 66 + 67 + - Docker and Docker Compose 68 + - `rdesktop` for RDP client 69 + - `netcat` (`nc`) for port checking 70 + - `curl` for web interface health checks 71 + - KVM support for hardware acceleration 72 + 73 + Thanks to https://github.com/dockur/windows for the windows docker image, that does all the hard work. 74 + 75 + ## Troubleshooting 76 + 77 + - **Container starts but RDP fails**: Check if Windows is fully booted via web interface at http://127.0.0.1:8006 78 + - **Slow startup**: Windows VM needs 2-3 minutes for full boot, script waits automatically 79 + - **Connection refused**: Ensure no other services are using ports 3389 or 8006 80 + - **Performance issues**: Verify KVM acceleration is available (`/dev/kvm` device) 81 + 82 + Perfect for occasional Windows-only tasks while staying in your Linux workflow.
+1 -1
hypr/.config/hypr/sspaeti/windows-ms/docker-compose.yml
··· 16 16 - 3389:3389/tcp 17 17 - 3389:3389/udp 18 18 volumes: 19 - - ~/windows:/storage 19 + - ~/Documents/VMs/windows:/storage 20 20 restart: always 21 21 stop_grace_period: 2m
+2 -2
hypr/.config/hypr/sspaeti/windows-ms/start-windows.sh
··· 5 5 # When RDP closes, docker-compose will also stop 6 6 7 7 SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" &> /dev/null && pwd)" 8 - RDP_COMMAND="rdesktop -g 1440x900 -P -z -x l -r sound:off -u docker 127.0.0.1:3389 -p admin" 8 + RDP_COMMAND="rdesktop -g 1920x1200 -P -z -x l -r sound:off -u docker 127.0.0.1:3389 -p admin" 9 9 10 10 echo "Starting Windows VM..." 11 11 ··· 67 67 68 68 echo "RDP port is open, testing connection..." 69 69 # Quick RDP test with shorter timeout 70 - timeout 5 rdesktop -g 1920x1200 -u docker 127.0.0.1:3389 -p admin 2>/dev/null 70 + timeout 5 rdesktop -g 320x240 -u docker 127.0.0.1:3389 -p admin 2>/dev/null 71 71 if [ $? -ne 0 ]; then 72 72 echo "RDP not fully ready yet, waiting 20 more seconds..." 73 73 sleep 20