summaryrefslogtreecommitdiff
path: root/ironic/drivers/modules/ipxe.py
diff options
context:
space:
mode:
authorJulia Kreger <juliaashleykreger@gmail.com>2018-10-19 11:35:38 -0700
committerJulia Kreger <juliaashleykreger@gmail.com>2018-10-25 16:27:00 +0000
commit38f6fff02e0db71a9b1e014b02e2ca09f13632e5 (patch)
treeb81076f629325d722ed246720a02411364ecf3ec /ironic/drivers/modules/ipxe.py
parentdd02698ad41774513aee0b123158c003e4af76eb (diff)
downloadironic-38f6fff02e0db71a9b1e014b02e2ca09f13632e5.tar.gz
Cleanup of remaining pxe focused is_ipxe_enabled
After this cleanup, only one use of is_ipxe_enabled remains which is in the storage interface. That will be removed in a separate patchset that I have been working on. Change-Id: I625ac56122ac4dd17d0c9e7dacc4444301a88e75 Story: 1628069
Diffstat (limited to 'ironic/drivers/modules/ipxe.py')
-rw-r--r--ironic/drivers/modules/ipxe.py15
1 files changed, 9 insertions, 6 deletions
diff --git a/ironic/drivers/modules/ipxe.py b/ironic/drivers/modules/ipxe.py
index 4eb687eb8..d9c95873e 100644
--- a/ironic/drivers/modules/ipxe.py
+++ b/ironic/drivers/modules/ipxe.py
@@ -156,7 +156,8 @@ class iPXEBoot(pxe_base.PXEBaseMixin, base.BootInterface):
pxe_utils.get_instance_image_info(task, ipxe_enabled=True))
boot_mode_utils.sync_boot_mode(task)
- pxe_options = pxe_utils.build_pxe_config_options(task, pxe_info)
+ pxe_options = pxe_utils.build_pxe_config_options(task, pxe_info,
+ ipxe_enabled=True)
pxe_options.update(ramdisk_params)
pxe_config_template = deploy_utils.get_pxe_config_template(node)
@@ -177,7 +178,7 @@ class iPXEBoot(pxe_base.PXEBaseMixin, base.BootInterface):
pxe_info.pop(ramdisk_label, None)
if pxe_info:
- pxe_utils.cache_ramdisk_kernel(task, pxe_info)
+ pxe_utils.cache_ramdisk_kernel(task, pxe_info, ipxe_enabled=True)
@METRICS.timer('iPXEBoot.prepare_instance')
def prepare_instance(self, task):
@@ -201,7 +202,8 @@ class iPXEBoot(pxe_base.PXEBaseMixin, base.BootInterface):
if boot_option == "ramdisk":
instance_image_info = pxe_utils.get_instance_image_info(
task, ipxe_enabled=True)
- pxe_utils.cache_ramdisk_kernel(task, instance_image_info)
+ pxe_utils.cache_ramdisk_kernel(task, instance_image_info,
+ ipxe_enabled=True)
if deploy_utils.is_iscsi_boot(task) or boot_option == "ramdisk":
pxe_utils.prepare_instance_pxe_config(
@@ -217,7 +219,8 @@ class iPXEBoot(pxe_base.PXEBaseMixin, base.BootInterface):
# This is for the takeover scenario for active nodes.
instance_image_info = pxe_utils.get_instance_image_info(
task, ipxe_enabled=True)
- pxe_utils.cache_ramdisk_kernel(task, instance_image_info)
+ pxe_utils.cache_ramdisk_kernel(task, instance_image_info,
+ ipxe_enabled=True)
# If it's going to PXE boot we need to update the DHCP server
dhcp_opts = pxe_utils.dhcp_options_for_instance(task,
@@ -244,7 +247,7 @@ class iPXEBoot(pxe_base.PXEBaseMixin, base.BootInterface):
"from deployment mode to service (boot) mode "
"for node %(node)s. Booting the instance "
"from disk.", {"node": task.node.uuid})
- pxe_utils.clean_up_pxe_config(task)
+ pxe_utils.clean_up_pxe_config(task, ipxe_enabled=True)
boot_device = boot_devices.DISK
else:
pxe_utils.build_service_pxe_config(task, instance_image_info,
@@ -256,7 +259,7 @@ class iPXEBoot(pxe_base.PXEBaseMixin, base.BootInterface):
# PXE config files. They still need to be generated as part
# of the prepare() because the deployment does PXE boot the
# deploy ramdisk
- pxe_utils.clean_up_pxe_config(task)
+ pxe_utils.clean_up_pxe_config(task, ipxe_enabled=True)
boot_device = boot_devices.DISK
# NOTE(pas-ha) do not re-set boot device on ACTIVE nodes