Merge pull request #165583 from bosu/patch-1

nixos/qemu-vm: allow booting VM with the custom kernel
This commit is contained in:
Robert Hensing 2022-04-04 14:33:35 +02:00 committed by GitHub
commit dd0d10bbb6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -854,7 +854,7 @@ in
"-device virtio-gpu-pci" "-device usb-ehci,id=usb0" "-device usb-kbd" "-device usb-tablet"
])
(mkIf (!cfg.useBootLoader) [
"-kernel ${config.system.build.toplevel}/kernel"
"-kernel \${NIXPKGS_QEMU_KERNEL_${config.system.name}:-${config.system.build.toplevel}/kernel}"
"-initrd ${config.system.build.toplevel}/initrd"
''-append "$(cat ${config.system.build.toplevel}/kernel-params) init=${config.system.build.toplevel}/init regInfo=${regInfo}/registration ${consoles} $QEMU_KERNEL_PARAMS"''
])