summaryrefslogtreecommitdiff
path: root/ironic/drivers/ipmi.py
diff options
context:
space:
mode:
authorDmitry Tantsur <divius.inside@gmail.com>2018-06-26 14:51:35 +0200
committerDmitry Tantsur <divius.inside@gmail.com>2018-06-27 13:08:42 +0200
commit1a07137118a95d72b3eb3b66121ee337fb989429 (patch)
tree05152ace090f7cca25f835f2f9167ea44a72e153 /ironic/drivers/ipmi.py
parent3d8f3ec1a985388a7639abffcb664639fd67855c (diff)
downloadironic-1a07137118a95d72b3eb3b66121ee337fb989429.tar.gz
Remove the ipmitool classic drivers
This change removes pxe_ipmitool and agent_ipmitool. Some tests and documentation bits are removed, since we no longer have any classic drivers to provide examples. The Inspector.create_if_enabled method is no longer used and was removed. The [inspector]enabled option will be deprecated in a follow-up. IRONIC_ENABLED_DRIVERS is removed from devstack to prevent devstack-gate from injecting the removed drivers into it. A temporary migration from queens is updated to disable all classic drivers. It will be removed when the enabled_drivers option is completely removed. Change-Id: Iab247e3b3336f90446ef0687edb340cf8282a925
Diffstat (limited to 'ironic/drivers/ipmi.py')
-rw-r--r--ironic/drivers/ipmi.py133
1 files changed, 0 insertions, 133 deletions
diff --git a/ironic/drivers/ipmi.py b/ironic/drivers/ipmi.py
index 7bdbc341a..8f41fba3f 100644
--- a/ironic/drivers/ipmi.py
+++ b/ironic/drivers/ipmi.py
@@ -14,19 +14,9 @@
Hardware types and classic drivers for IPMI (using ipmitool).
"""
-from oslo_config import cfg
-
-from ironic.drivers import base
from ironic.drivers import generic
-from ironic.drivers.modules import agent
-from ironic.drivers.modules import inspector
from ironic.drivers.modules import ipmitool
-from ironic.drivers.modules import iscsi_deploy
from ironic.drivers.modules import noop
-from ironic.drivers.modules import pxe
-
-
-CONF = cfg.CONF
class IPMIHardware(generic.GenericHardware):
@@ -56,126 +46,3 @@ class IPMIHardware(generic.GenericHardware):
def supported_vendor_interfaces(self):
"""List of supported vendor interfaces."""
return [ipmitool.VendorPassthru, noop.NoVendor]
-
-
-def _to_hardware_type():
- # NOTE(dtantsur): classic drivers are not affected by the
- # enabled_inspect_interfaces configuration option.
- if CONF.inspector.enabled:
- inspect_interface = 'inspector'
- else:
- inspect_interface = 'no-inspect'
-
- return {'boot': 'pxe',
- 'inspect': inspect_interface,
- 'management': 'ipmitool',
- 'power': 'ipmitool',
- 'raid': 'agent',
- 'vendor': 'ipmitool'}
-
-
-class PXEAndIPMIToolDriver(base.BaseDriver):
- """PXE + IPMITool driver.
-
- This driver implements the `core` functionality, combining
- :class:`ironic.drivers.modules.ipmitool.IPMIPower` for power on/off
- and reboot with
- :class:`ironic.drivers.modules.iscsi_deploy.ISCSIDeploy` for
- image deployment. Implementations are in those respective
- classes; this class is merely the glue between them.
- """
- def __init__(self):
- self.power = ipmitool.IPMIPower()
- self.console = ipmitool.IPMIShellinaboxConsole()
- self.boot = pxe.PXEBoot()
- self.deploy = iscsi_deploy.ISCSIDeploy()
- self.management = ipmitool.IPMIManagement()
- self.inspect = inspector.Inspector.create_if_enabled(
- 'PXEAndIPMIToolDriver')
- self.vendor = ipmitool.VendorPassthru()
- self.raid = agent.AgentRAID()
-
- @classmethod
- def to_hardware_type(cls):
- return 'ipmi', dict(_to_hardware_type(),
- console='ipmitool-shellinabox',
- deploy='iscsi')
-
-
-class PXEAndIPMIToolAndSocatDriver(PXEAndIPMIToolDriver):
- """PXE + IPMITool + socat driver.
-
- This driver implements the `core` functionality, combining
- :class:`ironic.drivers.modules.ipmitool.IPMIPower` for power on/off
- and reboot with
- :class:`ironic.drivers.modules.iscsi_deploy.ISCSIDeploy` (for
- image deployment) and with
- :class:`ironic.drivers.modules.ipmitool.IPMISocatConsole`.
- This driver uses the socat console interface instead of the shellinabox
- one.
- Implementations are in those respective
- classes; this class is merely the glue between them.
- """
- def __init__(self):
- PXEAndIPMIToolDriver.__init__(self)
- self.console = ipmitool.IPMISocatConsole()
-
- @classmethod
- def to_hardware_type(cls):
- return 'ipmi', dict(_to_hardware_type(),
- console='ipmitool-socat',
- deploy='iscsi')
-
-
-class AgentAndIPMIToolDriver(base.BaseDriver):
- """Agent + IPMITool driver.
-
- This driver implements the `core` functionality, combining
- :class:`ironic.drivers.modules.ipmitool.IPMIPower` (for power on/off and
- reboot) with :class:`ironic.drivers.modules.agent.AgentDeploy` (for
- image deployment).
- Implementations are in those respective classes; this class is merely the
- glue between them.
- """
-
- def __init__(self):
- self.power = ipmitool.IPMIPower()
- self.boot = pxe.PXEBoot()
- self.deploy = agent.AgentDeploy()
- self.management = ipmitool.IPMIManagement()
- self.console = ipmitool.IPMIShellinaboxConsole()
- self.vendor = ipmitool.VendorPassthru()
- self.raid = agent.AgentRAID()
- self.inspect = inspector.Inspector.create_if_enabled(
- 'AgentAndIPMIToolDriver')
-
- @classmethod
- def to_hardware_type(cls):
- return 'ipmi', dict(_to_hardware_type(),
- console='ipmitool-shellinabox',
- deploy='direct')
-
-
-class AgentAndIPMIToolAndSocatDriver(AgentAndIPMIToolDriver):
- """Agent + IPMITool + socat driver.
-
- This driver implements the `core` functionality, combining
- :class:`ironic.drivers.modules.ipmitool.IPMIPower` (for power on/off and
- reboot) with :class:`ironic.drivers.modules.agent.AgentDeploy` (for
- image deployment) and with
- :class:`ironic.drivers.modules.ipmitool.IPMISocatConsole`.
- This driver uses the socat console interface instead of the shellinabox
- one.
- Implementations are in those respective classes; this class is merely the
- glue between them.
- """
-
- def __init__(self):
- AgentAndIPMIToolDriver.__init__(self)
- self.console = ipmitool.IPMISocatConsole()
-
- @classmethod
- def to_hardware_type(cls):
- return 'ipmi', dict(_to_hardware_type(),
- console='ipmitool-socat',
- deploy='direct')