def is_cdrom(self): """ Checks if nova allows mapping a volume as cdrom drive. This is only available starting with Havana @return: True if volume can be attached as cdrom """ nova_extension_manager = ListExtManager(self.nova) for ext in nova_extension_manager.show_all(): if ext.name == "BlockDeviceMappingV2Boot" and ext.is_loaded(): return True return False
def is_floppy(self): #TODO: check if floppy is available. """ Checks if nova allows mapping a volume as a floppy drive. This will not be available until Icehouse @return: Currently this always returns True. """ nova_extension_manager = ListExtManager(self.nova) for ext in nova_extension_manager.show_all(): if ext.name == "BlockDeviceMappingV2Boot" and ext.is_loaded(): return True return False
def list_extensions(request): return ListExtManager(novaclient(request)).show_all()