Deprecate elilo support

The elilo project has been orphaned and dropped from
the majority of linux distributions. Effectively, it has
already been deprecated by the larger ecosystem, and removal
from ironic only seems appropriate as time goes on.

Partial-Bug: #1691454
Change-Id: I725dc11978f6a641ffdbe3146527d67fe126debe
This commit is contained in:
Julia Kreger 2017-05-17 00:28:52 +00:00 committed by Ruby Loo
parent dbe6800a13
commit bd5b1a72e0
5 changed files with 25 additions and 0 deletions

View File

@ -138,6 +138,8 @@ def _get_pxe_ip_address_path(ip_address, hex_form):
:returns: the path to the config file.
"""
# NOTE(TheJulia): Remove elilo support after the deprecation
# period, in the Queens release.
# elilo bootloader needs hex based config file name.
if hex_form:
ip = ip_address.split('.')
@ -216,6 +218,9 @@ def create_pxe_config(task, pxe_options, template=None):
hex_form = False
pxe_config_root_tag = '(( ROOT ))'
pxe_config_disk_ident = '(( DISK_IDENTIFIER ))'
LOG.warning("The requested config appears to support elilo. "
"Support for elilo has been deprecated and will be "
"removed in the Queens release of OpenStack.")
else:
# TODO(stendulker): We should use '(' ')' as the delimiters for all our
# config files so that we do not need special handling for each of the
@ -257,6 +262,8 @@ def clean_up_pxe_config(task):
# Get xx.xx.xx.xx based grub config file
ip_address_path = _get_pxe_ip_address_path(port_ip_address,
False)
# NOTE(TheJulia): Remove elilo support after the deprecation
# period, in the Queens release.
# Get 0AOAOAOA based elilo config file
hex_ip_path = _get_pxe_ip_address_path(port_ip_address,
True)

View File

@ -1,3 +1,4 @@
{#- NOTE(TheJulia): Remove elilo support after the deprecation period, in the Queens release. -#}
default=deploy
image={{pxe_options.deployment_aki_path}}

View File

@ -133,6 +133,8 @@ class TestPXEUtils(db_base.DbTestCase):
self.assertEqual(six.text_type(expected_template), rendered_template)
# NOTE(TheJulia): Remove elilo support after the deprecation period,
# in the Queens release.
def test_default_elilo_config(self):
pxe_opts = self.pxe_options
pxe_opts['boot_mode'] = 'uefi'
@ -361,6 +363,8 @@ class TestPXEUtils(db_base.DbTestCase):
write_mock.assert_called_with(pxe_cfg_file_path,
render_mock.return_value)
# NOTE(TheJulia): Remove elilo support after the deprecation period,
# in the Queens release.
@mock.patch.object(os, 'chmod', autospec=True)
@mock.patch('ironic.common.pxe_utils._link_ip_address_pxe_configs',
autospec=True)

View File

@ -789,6 +789,8 @@ class PhysicalWorkTestCase(tests_base.TestCase):
class SwitchPxeConfigTestCase(tests_base.TestCase):
# NOTE(TheJulia): Remove elilo support after the deprecation period,
# in the Queens release.
def _create_config(self, ipxe=False, boot_mode=None, boot_loader='elilo'):
(fd, fname) = tempfile.mkstemp()
if boot_mode == 'uefi' and not ipxe:
@ -860,6 +862,8 @@ class SwitchPxeConfigTestCase(tests_base.TestCase):
pxeconf = f.read()
self.assertEqual(_IPXECONF_BOOT_WHOLE_DISK, pxeconf)
# NOTE(TheJulia): Remove elilo support after the deprecation period,
# in the Queens release.
def test_switch_uefi_elilo_pxe_config_partition_image(self):
boot_mode = 'uefi'
fname = self._create_config(boot_mode=boot_mode)
@ -871,6 +875,8 @@ class SwitchPxeConfigTestCase(tests_base.TestCase):
pxeconf = f.read()
self.assertEqual(_UEFI_PXECONF_BOOT_PARTITION, pxeconf)
# NOTE(TheJulia): Remove elilo support after the deprecation period,
# in the Queens release.
def test_switch_uefi_elilo_config_whole_disk_image(self):
boot_mode = 'uefi'
fname = self._create_config(boot_mode=boot_mode)

View File

@ -0,0 +1,7 @@
---
deprecations:
- |
Support for the ``elilo`` boot loader has been deprecated and will
be removed in the Queens release cycle. The elilo boot loader has
been orphaned as a project and dropped from the majority of Linux
distributions. Please switch to the ``grub2`` boot loader.