Merge pull request #47067 from gtmanfred/2017.7

use the recommended opennebula lookup method
This commit is contained in:
Daniel Wallace 2018-04-16 10:48:14 -05:00 committed by GitHub
commit ca967de5da
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4571,7 +4571,7 @@ def _list_nodes(full=False):
pass
vms[name]['id'] = vm.find('ID').text
if vm.find('TEMPLATE').find('TEMPLATE_ID'):
if 'TEMPLATE_ID' in vm.find('TEMPLATE'):
vms[name]['image'] = vm.find('TEMPLATE').find('TEMPLATE_ID').text
vms[name]['name'] = name
vms[name]['size'] = {'cpu': cpu_size, 'memory': memory_size}