Mario Ubeda Garcia created LIBCLOUD-443:
-------------------------------------------
Summary: OpenNebula driver : create_node with N disks
Key: LIBCLOUD-443
URL: https://issues.apache.org/jira/browse/LIBCLOUD-443
Project: Libcloud
Issue Type: Wish
Components: Compute
Reporter: Mario Ubeda Garcia
Priority: Trivial
Hi,
I'd like to have the possibility to boot a VM in OpenNebula with more than one
disk; in particular, my use case is one disk - type OS -, another disk - type
CDROM.
I took a look to the code and seems a "trivial" change:
https://github.com/apache/libcloud/blob/trunk/libcloud/compute/drivers/opennebula.py#L685
from
{code}
disk = ET.SubElement(compute, 'DISK')
ET.SubElement(disk,
'STORAGE',
{'href': '/storage/%s' % (str(kwargs['image'].id))})
{code}
to
{code}
disk = ET.SubElement(compute, 'DISK')
if not isinstance(kwargs['image'], list):
kwargs['image'] = [kwargs['image']]
for image in kwargs[ 'image' ]:
ET.SubElement(disk,
'STORAGE',
{'href': '/storage/%s' % (str(image.id))})
{code}
I would be happy making the changes myself if you agree.
Many thanks in advance,
Mario.
--
This message was sent by Atlassian JIRA
(v6.1#6144)