Read port forwards from per-VM forwards.conf files
A QEMU config file section cannot hold more than one hostfwd entry, so the forwards move out of the ini files into qemu/<vm>/forwards.conf, one "LABEL HOST_PORT GUEST_PORT" rule per line. The new vmforwards.py parses them, skips rules whose host port is taken and builds the -netdev argument, which every launcher now passes instead of relying on a netdev section in the ini or on -nic. The ini files move to qemu/<vm>/config.ini and qemu/<vm>/<os>-<arch>.ini. The *_SSH_PORT / *_RDP_PORT variables and --rdp-port / --ssh-port still replace the host port of the SSH and RDP rules. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
07a2c6db3e
commit
78f6fd424b
29 files changed
+272
-131
No files matched your search
@@ -0,0 +1,38 @@
|
||||
# Linux host, arm64 part of the Windows 11 QEMU configuration; read after config.ini.
|
||||
|
||||
# Accelerators are tried in order: KVM on Linux, else emulation.
|
||||
[accel]
|
||||
accel = "kvm"
|
||||
|
||||
[accel]
|
||||
accel = "tcg"
|
||||
|
||||
[machine]
|
||||
type = "virt"
|
||||
|
||||
# The "virt" machine has no IDE. NVMe and USB mass storage (used by the
|
||||
# installation media of --install-from-iso) both have inbox Windows drivers.
|
||||
[device "system_disk-dev"]
|
||||
driver = "nvme"
|
||||
drive = "system_disk"
|
||||
serial = "win11disk"
|
||||
bootindex = "1"
|
||||
|
||||
# Windows has no inbox driver for virtio-net; the guest tools installed by
|
||||
# Configure-Windows.ps1 provide it.
|
||||
[device "nic0"]
|
||||
driver = "virtio-net-pci"
|
||||
netdev = "net0"
|
||||
|
||||
# Unlike q35, "virt" has no default GPU or keyboard. virtio-gpu is the only
|
||||
# display, driven by viogpudo (installed by Configure-Windows.ps1). ramfb is not
|
||||
# added because Windows would then see a second adapter with a fixed-mode
|
||||
# monitor. xres/yres set the preferred mode in the EDID (QEMU defaults to
|
||||
# 1280x800); viogpudo accepted 1920x1200 and 2048x1280 but not 2560x1600.
|
||||
[device "gpu0"]
|
||||
driver = "virtio-gpu-pci"
|
||||
xres = "2048"
|
||||
yres = "1280"
|
||||
|
||||
[device "kbd0"]
|
||||
driver = "usb-kbd"
|
||||
Reference in new issue
Block a user