Do not use "ide" if there is a disk image and no interface type has been explicitly configured.

This commit is contained in:
grossmj committed 2024-11-07 14:37:26 +10:00
1 parent fb06eb3c0c
commit 7bf17392dd
2 files changed
+10 -8

No files matched your search

-5
View File
@@ -1915,11 +1915,6 @@ class QemuVM(BaseNode):
continue
interface = getattr(self, "hd{}_disk_interface".format(drive))
# fail-safe: use "ide" if there is a disk image and no interface type has been explicitly configured
if interface == "none":
interface = "ide"
setattr(self, "hd{}_disk_interface".format(drive), interface)
disk_name = "hd" + drive
if not os.path.isfile(disk_image) or not os.path.exists(disk_image):
if os.path.islink(disk_image):