value_string = remctl('web', 'listvms')
lines = value_string.splitlines()
d = {}
- for line in lines[1:]:
+ for line in lines:
lst = line.split()
name, id = lst[:2]
uptime = ' '.join(lst[2:])
]
fields = []
machine_info = {}
+ machine_info['name'] = machine.name
machine_info['type'] = machine.type.hvm and 'HVM' or 'ParaVM'
machine_info['owner'] = machine.owner
machine_info['contact'] = machine.contact
for field, disp in display_fields:
if field in ('uptime', 'cputime'):
fields.append((disp, locals()[field]))
- elif field in main_status:
- fields.append((disp, main_status[field]))
elif field in machine_info:
fields.append((disp, machine_info[field]))
+ elif field in main_status:
+ fields.append((disp, main_status[field]))
else:
pass
#fields.append((disp, None))