Skip to content

Commit d40f655

Browse files
committed
Add windows vagrantfile
1 parent 8a2dabd commit d40f655

File tree

2 files changed

+45
-0
lines changed

2 files changed

+45
-0
lines changed

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,11 @@ Requires Xcode Command Line Tools
4545
```bash
4646
bash ./scripts/build-macos.sh
4747
```
48+
49+
### Vagrant VMs (optional)
50+
For quick cross-OS testing in VMs using VirtualBox:
51+
52+
- Ubuntu Desktop: `cd vagrant/ubuntu; vagrant up`
53+
- Windows 11: `cd vagrant/windows; vagrant up`
54+
55+
Both VMs sync the repo into the guest (`/mnt/derpiwallpaper` on Ubuntu, `C:\derpiwallpaper` on Windows).

vagrant/windows/Vagrantfile

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# -*- mode: ruby -*-
2+
# vi: set ft=ruby :
3+
4+
# Windows development VM for DerpiWallpaper
5+
Vagrant.configure("2") do |config|
6+
# Use a prebuilt Windows 11 box (VirtualBox provider supported)
7+
# Other options include: gusztavvargadr/windows-10 or windows-2022 for Server
8+
config.vm.box = "gusztavvargadr/windows-11"
9+
10+
# Explicitly mark guest type and communicator
11+
config.vm.guest = :windows
12+
config.vm.communicator = "winrm"
13+
14+
# Increase boot timeout; Windows boots can take longer
15+
config.vm.boot_timeout = 900
16+
17+
# Sync the repository into the guest
18+
# On Windows guests, using VirtualBox shared folders avoids SMB credential prompts
19+
config.vm.synced_folder "../../", "C:/derpiwallpaper", type: "virtualbox"
20+
21+
# Optional: forward RDP for convenience (GUI is usually shown by provider as well)
22+
# config.vm.network "forwarded_port", guest: 3389, host: 53389, auto_correct: true
23+
config.vm.network "forwarded_port", guest: 22, host: 2224, id: "ssh", auto_correct: true
24+
25+
# VirtualBox provider tweaks
26+
config.vm.provider "virtualbox" do |vb|
27+
vb.gui = true
28+
vb.memory = "4096"
29+
vb.cpus = 2
30+
end
31+
32+
# Example PowerShell provisioning (disabled by default)
33+
# config.vm.provision "shell", inline: <<-POWERSHELL
34+
# Write-Output "Windows VM ready for DerpiWallpaper"
35+
# POWERSHELL
36+
end
37+

0 commit comments

Comments
 (0)