ironic.drivers.modules.noop module¶
Dummy interface implementations for use as defaults with optional interfaces.
Note that unlike fake implementations, these do not pass validation and raise exceptions for user-accessible actions.
-
class
ironic.drivers.modules.noop.
FailMixin
[source]¶ Bases:
object
Mixin to add to an interface to make it fail validation.
-
validate
(task, *args, **kwargs)¶
-
-
class
ironic.drivers.modules.noop.
NoBIOS
[source]¶ Bases:
ironic.drivers.modules.noop.FailMixin
,ironic.drivers.base.BIOSInterface
BIOS interface implementation that raises errors on all requests.
-
apply_configuration
(task, settings)[source]¶ Validate & apply BIOS settings on the given node.
This method takes the BIOS settings from the settings param and applies BIOS settings on the given node. It may also validate the given bios settings before applying any settings and manage failures when setting an invalid BIOS config. In the case of needing password to update the BIOS config, it will be taken from the driver_info properties. After the BIOS configuration is done, cache_bios_settings will be called to update the node’s BIOS setting table with the BIOS configuration applied on the node.
- Parameters
task – a TaskManager instance.
settings – Dictonary containing the BIOS configuration.
- Raises
UnsupportedDriverExtension, if the node’s driver doesn’t support BIOS configuration.
- Raises
InvalidParameterValue, if validation of settings fails.
- Raises
MissingParameterValue, if some required parameters are missing.
- Returns
states.CLEANWAIT if BIOS configuration is in progress asynchronously or None if it is complete.
-
cache_bios_settings
(task)[source]¶ Store or update BIOS properties on the given node.
This method stores BIOS properties to the bios_settings table during ‘cleaning’ operation and updates bios_settings table when apply_configuration() and factory_reset() are called to set new BIOS configurations. It will also update the timestamp of each bios setting.
- Parameters
task – a TaskManager instance.
- Raises
UnsupportedDriverExtension, if the node’s driver doesn’t support getting BIOS properties from bare metal.
- Returns
None.
-
factory_reset
(task)[source]¶ Reset BIOS configuration to factory default on the given node.
This method resets BIOS configuration to factory default on the given node. After the BIOS reset action is done, cache_bios_settings will be called to update the node’s BIOS settings table with default bios settings.
- Parameters
task – a TaskManager instance.
- Raises
UnsupportedDriverExtension, if the node’s driver doesn’t support BIOS reset.
- Returns
states.CLEANWAIT if BIOS configuration is in progress asynchronously or None if it is complete.
-
-
class
ironic.drivers.modules.noop.
NoConsole
[source]¶ Bases:
ironic.drivers.modules.noop.FailMixin
,ironic.drivers.base.ConsoleInterface
Console interface implementation that raises errors on all requests.
-
get_console
(task, *args, **kwargs)¶
-
start_console
(task, *args, **kwargs)¶
-
stop_console
(task, *args, **kwargs)¶
-
-
class
ironic.drivers.modules.noop.
NoInspect
[source]¶ Bases:
ironic.drivers.modules.noop.FailMixin
,ironic.drivers.base.InspectInterface
Inspect interface implementation that raises errors on all requests.
-
inspect_hardware
(task, *args, **kwargs)¶
-
-
class
ironic.drivers.modules.noop.
NoRAID
[source]¶ Bases:
ironic.drivers.modules.noop.FailMixin
,ironic.drivers.base.RAIDInterface
RAID interface implementation that raises errors on all requests.
-
create_configuration
(task, *args, **kwargs)¶
-
delete_configuration
(task, *args, **kwargs)¶
-
validate_raid_config
(task, raid_config)[source]¶ Validates the given RAID configuration.
This method validates the given RAID configuration. Driver implementations of this interface can override this method to support custom parameters for RAID configuration.
- Parameters
task – A TaskManager instance.
raid_config – The RAID configuration to validate.
- Raises
InvalidParameterValue, if the RAID configuration is invalid.
-
-
class
ironic.drivers.modules.noop.
NoRescue
[source]¶ Bases:
ironic.drivers.modules.noop.FailMixin
,ironic.drivers.base.RescueInterface
Rescue interface implementation that raises errors on all requests.
-
rescue
(task, *args, **kwargs)¶
-
unrescue
(task, *args, **kwargs)¶
-
-
class
ironic.drivers.modules.noop.
NoVendor
[source]¶ Bases:
ironic.drivers.modules.noop.FailMixin
,ironic.drivers.base.VendorInterface
Vendor interface implementation that raises errors on all requests.
-
driver_validate
(method, **kwargs)[source]¶ Validate driver-vendor-passthru actions.
If invalid, raises an exception; otherwise returns None.
- Parameters
method – method to be validated
kwargs – info for action.
- Raises
MissingParameterValue if kwargs does not contain certain parameter.
- Raises
InvalidParameterValue if parameter does not match.
-