ironic_python_agent.extensions.image module

class ironic_python_agent.extensions.image.ImageExtension(agent=None)[source]

Bases: ironic_python_agent.extensions.base.BaseAgentExtension

install_bootloader(root_uuid, efi_system_part_uuid=None, prep_boot_part_uuid=None, target_boot_mode='bios', ignore_bootloader_failure=None)[source]

Install the GRUB2 bootloader on the image.

Parameters
  • root_uuid – The UUID of the root partition.

  • efi_system_part_uuid – The UUID of the efi system partition. To be used only for uefi boot mode. For uefi boot mode, the boot loader will be installed here.

  • prep_boot_part_uuid – The UUID of the PReP Boot partition. Used only for booting ppc64* partition images locally. In this scenario the bootloader will be installed here.

  • target_boot_mode – bios, uefi. Only taken into account for softraid, when no efi partition is explicitely provided (happens for whole disk images)

Raises

CommandExecutionError if the installation of the bootloader fails.

Raises

DeviceNotFound if the root partition is not found.