From 7309946b23f26114aa39336ca4ab0aa8c6c52f12 Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Thu, 2 May 2024 17:08:35 +0900 Subject: [PATCH] pxe: Remove enable_ppc64le The parameter was deprecated in favor of the native parameters to set the required options. Change-Id: I937f70ac730ac5af9446cb4e969e7bf6f6c4e593 --- manifests/drivers/pxe.pp | 37 ++----------------- ...emove-enable_ppc64le-85044a8ea4b8ea81.yaml | 5 +++ spec/classes/ironic_drivers_pxe_spec.rb | 13 ------- 3 files changed, 8 insertions(+), 47 deletions(-) create mode 100644 releasenotes/notes/remove-enable_ppc64le-85044a8ea4b8ea81.yaml diff --git a/manifests/drivers/pxe.pp b/manifests/drivers/pxe.pp index 876db794..e36fda5f 100644 --- a/manifests/drivers/pxe.pp +++ b/manifests/drivers/pxe.pp @@ -127,12 +127,6 @@ # (optional) Template file for PXE configuration per node architecture. # Defaults to $facts['os_service_default']. # -# DEPRECATED PARAMETERS -# -# [*enable_ppc64le*] -# (optional) Boolean value to dtermine if ppc64le support should be enabled -# Defaults to false (no ppc64le support) -# class ironic::drivers::pxe ( $kernel_append_params = $facts['os_service_default'], $pxe_bootfile_name = $facts['os_service_default'], @@ -156,8 +150,6 @@ class ironic::drivers::pxe ( $pxe_bootfile_name_by_arch = $facts['os_service_default'], $ipxe_bootfile_name_by_arch = $facts['os_service_default'], $pxe_config_template_by_arch = $facts['os_service_default'], - # DEPRECATED PARAMETERS - Boolean $enable_ppc64le = false, ) inherits ironic::params { include ironic::deps @@ -209,33 +201,10 @@ class ironic::drivers::pxe ( default => join(any2array($pxe_config_template_by_arch), ',') } - if $enable_ppc64le { - warning("The enable_ppc64le parameter is deprecated. \ -Use the pxe_config_template_by_arch parameter and the pxe_bootfile_name_by_arch parameter \ -to configure the required options") - - # FXIME(tonyb): As these are really hash values it would be better to model - # them that way. We can do that later, probably when we add another - # architecture - ironic_config { - # NOTE(tonyb): This first value shouldn't be needed but seems to be? - # NOTE(TheJulia): Likely not needed as this just points to the default, - # and when the explicit pxe driver is used everything should fall to - # it but in the interest of minimizing impact, the output result - # is preserved as we now just allow the default for normal template - # operation to be used. - 'pxe/pxe_config_template_by_arch': value => 'ppc64le:$pybasedir/drivers/modules/pxe_config.template'; - 'pxe/pxe_bootfile_name_by_arch': value => 'ppc64le:config'; - } - } else { - ironic_config { - 'pxe/pxe_config_template_by_arch': value => $pxe_config_template_by_arch_real; - 'pxe/pxe_bootfile_name_by_arch': value => $pxe_bootfile_name_by_arch_real; - } - } - ironic_config { - 'pxe/ipxe_bootfile_name_by_arch': value => $ipxe_bootfile_name_by_arch_real; + 'pxe/pxe_config_template_by_arch': value => $pxe_config_template_by_arch_real; + 'pxe/pxe_bootfile_name_by_arch': value => $pxe_bootfile_name_by_arch_real; + 'pxe/ipxe_bootfile_name_by_arch': value => $ipxe_bootfile_name_by_arch_real; } } diff --git a/releasenotes/notes/remove-enable_ppc64le-85044a8ea4b8ea81.yaml b/releasenotes/notes/remove-enable_ppc64le-85044a8ea4b8ea81.yaml new file mode 100644 index 00000000..a8d7f38d --- /dev/null +++ b/releasenotes/notes/remove-enable_ppc64le-85044a8ea4b8ea81.yaml @@ -0,0 +1,5 @@ +--- +upgrade: + - | + The deprecated ``ironic::drivers::pxe::enable_ppc64le`` parameter has been + removed. diff --git a/spec/classes/ironic_drivers_pxe_spec.rb b/spec/classes/ironic_drivers_pxe_spec.rb index a293afe1..5eaf1bad 100644 --- a/spec/classes/ironic_drivers_pxe_spec.rb +++ b/spec/classes/ironic_drivers_pxe_spec.rb @@ -49,19 +49,6 @@ describe 'ironic::drivers::pxe' do is_expected.to contain_ironic_config('pxe/pxe_config_template_by_arch').with_value('') end - context 'when overriding only enable_ppc64le' do - before do - params.merge!( - :enable_ppc64le => true, - ) - end - - it 'detects correct ppc64le parameters' do - is_expected.to contain_ironic_config('pxe/pxe_config_template_by_arch').with_value('ppc64le:$pybasedir/drivers/modules/pxe_config.template') - is_expected.to contain_ironic_config('pxe/pxe_bootfile_name_by_arch').with_value('ppc64le:config') - end - end - context 'when overriding parameters' do before do params.merge!(