Activity log for bug #2045551

Date Who What changed Old value New value Message
2023-12-04 11:20:17 Dmitry Tantsur bug added bug
2023-12-04 11:22:07 Dmitry Tantsur description Currently in case of unmanaged inspection, the corresponding iPXE script has to be configured manually. This is an error-prone process and leads to duplication of certain configuration options, e.g. for Metal3: https://github.com/metal3-io/ironic-image/blob/bea232575143470f94528d3da6d78e6d0019d241/ironic-config/ironic.conf.j2#L140 https://github.com/metal3-io/ironic-image/blob/bea232575143470f94528d3da6d78e6d0019d241/ironic-config/inspector.ipxe.j2#L8 We already have some bits necessary for this feature: Ironic generates the root boot.ipxe which can fall back to the inspection script specified via the [pxe]ipxe_fallback_script option. Now we just need to generate this script from the information we already have, namely: 1) [conductor]deploy_kernel/ramdisk (NOTE: no multi-arch support at this point) 2) [pxe]ipxe_fallback_script option 3) Various [inspector] options The new logic will leave in the iPXE boot interface and rely on one new options: 4) [pxe]generate_ipxe_inspection_script = True/False (default False) When this option is set to True, the iPXE boot interface will launch a new thread in its __init__ that will download the images and create the fallback script. Why a thread? Because we cannot rely on Keystone and Glance to be already available when Ironic starts, nor do I want to delay the start-up while IPA is downloading. Unfortunately, the only way to detect a problem will be by checking the logs. Currently in case of unmanaged inspection, the corresponding iPXE script has to be configured manually. This is an error-prone process and leads to duplication of certain configuration options, e.g. for Metal3: https://github.com/metal3-io/ironic-image/blob/bea232575143470f94528d3da6d78e6d0019d241/ironic-config/ironic.conf.j2#L140 https://github.com/metal3-io/ironic-image/blob/bea232575143470f94528d3da6d78e6d0019d241/ironic-config/inspector.ipxe.j2#L8 We already have some bits necessary for this feature: Ironic generates the root boot.ipxe which can fall back to the inspection script specified via the [pxe]ipxe_fallback_script option. Now we just need to generate this script from the information we already have, namely: 1) [conductor]deploy_kernel/ramdisk (NOTE: no multi-arch support at this point) 2) [pxe]ipxe_fallback_script option 3) Various [inspector] options The new logic will leave in the iPXE boot interface and rely on one new options: 4) [pxe]generate_ipxe_inspection_script = True/False (default False) When this option is set to True, the iPXE boot interface will launch a new thread in its __init__ that will download the images and create the fallback script. Why a thread? Because we cannot rely on Keystone and Glance to be already available when Ironic starts, nor do I want to delay the start-up while IPA is downloading. Unfortunately, the only way to detect a problem will be by checking the logs. NOTE: this proposal is a revival of https://storyboard.openstack.org/#!/story/2009294.
2023-12-11 15:48:31 Jay Faulkner tags rfe-approved