mirror of
https://github.com/retspen/webvirtcloud.git
synced 2026-06-08 05:14:36 +00:00
fix add-cdrom error while creating
This commit is contained in:
@@ -249,7 +249,6 @@ class wvmCreate(wvmConnect):
|
|||||||
|
|
||||||
|
|
||||||
for volume in volumes:
|
for volume in volumes:
|
||||||
|
|
||||||
disk_opts = ""
|
disk_opts = ""
|
||||||
if volume["cache_mode"] is not None and volume["cache_mode"] != "default":
|
if volume["cache_mode"] is not None and volume["cache_mode"] != "default":
|
||||||
disk_opts += f"cache='{volume['cache_mode']}' "
|
disk_opts += f"cache='{volume['cache_mode']}' "
|
||||||
@@ -264,7 +263,7 @@ class wvmCreate(wvmConnect):
|
|||||||
stg_type = util.get_xml_path(stg.XMLDesc(0), "/pool/@type")
|
stg_type = util.get_xml_path(stg.XMLDesc(0), "/pool/@type")
|
||||||
|
|
||||||
if volume["device"] == "cdrom":
|
if volume["device"] == "cdrom":
|
||||||
add_cdrom = None
|
add_cdrom = "None"
|
||||||
|
|
||||||
if stg_type == "rbd":
|
if stg_type == "rbd":
|
||||||
ceph_user, secret_uuid, ceph_hosts = get_rbd_storage_data(stg)
|
ceph_user, secret_uuid, ceph_hosts = get_rbd_storage_data(stg)
|
||||||
|
|||||||
Reference in New Issue
Block a user