Add support for boot and driver ISO image
Installing Windows 10 in VirtIO enabled Qemu requires additional drivers. This change makes it possible to exposed those drivers during a Windows 10 install.
This commit is contained in:
parent
e8ddb13e9b
commit
c94b6a0a56
12
quickemu
12
quickemu
@ -148,6 +148,16 @@ function vm_boot() {
|
||||
echo " Existing disk state will be preserved, no writes will be committed."
|
||||
fi
|
||||
|
||||
if [ -n "${iso}" ] && [ -e "${iso}" ]; then
|
||||
local ISO_BOOT="-drive media=cdrom,file="${iso}",index=2"
|
||||
echo " - Boot: ${iso}"
|
||||
fi
|
||||
|
||||
if [ -n "${driver_iso}" ] && [ -e "${driver_iso}" ]; then
|
||||
local ISO_DRIVER="-drive media=cdrom,file="${driver_iso}",index=3"
|
||||
echo " - Drivers: ${driver_iso}"
|
||||
fi
|
||||
|
||||
local cores="1"
|
||||
local allcores=$(nproc --all)
|
||||
if [ ${allcores} -ge 8 ]; then
|
||||
@ -222,8 +232,8 @@ function vm_boot() {
|
||||
# Boot the iso image
|
||||
${QEMU} -name ${VMNAME},process=${VMNAME} \
|
||||
${BIOS} \
|
||||
-cdrom "${iso}" \
|
||||
-drive id=disk,file=${disk_img},format=qcow2,if=virtio,aio=native,cache.direct=on \
|
||||
${ISO_BOOT} ${ISO_DRIVER} \
|
||||
-enable-kvm \
|
||||
-machine q35,accel=kvm \
|
||||
-cpu host,kvm=on \
|
||||
|
Loading…
Reference in New Issue
Block a user