This patch introduces a simple JSON-based DSL to run on introspected
data. Conditions and actions are provided via new plugin entry points.
This patch is missing PUT operation on a rule, this can be added later.
Also not all planned conditions and actions are added in this patch,
will also follow up.
Implements: blueprint rules
Change-Id: If4d17b5f1462d03879cb4c2ff4e5cb3ea364b697
This code makes assumption that importing oslo_config.cfg is enough
to get our options, which is of course not true. It happens to work now,
as we seem to import ironic_inspector.conf (actual module defining
configuration options) somewhere else before this code is run.
When building an RPM, however, we run tests a bit differently, and
this problems leads to NoSuchOptError: no such option:
introspection_delay_drivers.
Closes-Bug: #1494649
Change-Id: I3524222418a12270c78c6ee61d4a4afa1353306e
Allows for much cleaner and complete testing, also simplifies future
changes.
Change-Id: Ia586c21ff8e6e6449c6048d4764d1d12259ab0ba
Partial-Bug: #1492946
Accept ironic object in NodeInfo __init__ instead of every method
to reduce number of times we need to pass it around.
Add new methods to NodeInfo: patch, update_properties,
update_capabilities, patch_port and delete_port.
Change-Id: Ida03ac70e743f53f887bb194f61b0011950d4dfd
Partial-Bug: #1492946
* Recommend using ENROLL for setting IPMI credentials
* Deprecate using maintenance mode, will be dropped once we stop
supporting Ironic Kilo
* Drop bits related to Ironic Juno, we no longer support it
* Clarify error message about wrong provision state, stop mentioning
maintenance mode there
Change-Id: I3a9d3ba24a32c7844cd6fd5e4f8ec4b15b2d9d20
Closes-Bug: #1479331
This adds the ability to store all of the data collected
during introspection. The configuration option
"[processing] store_data" (defaults to 'none'), determines
this behavior. Initially, only 'none' and 'swift' are
supported. If 'swift' is used, the data is stored in Swift
with the object name of "inspector_data-<UUID>".
Adds an endpoint /v1/introspection/<UUID>/data which
retrieves the data according to the method in
"[processing] store_data". Returns 404 if this option
is disabled.
There is a further option to store the location of the data
in the Ironic Node.extra column. For 'swift', this will be
the name of the swift object. The option,
"[processing] store_data_location" determines the key
name in the Node.extra column. (defaults to not storing
the location).
Change-Id: Ibc38064f7ea56f85b9f5a77ef6f62a50f0381ff4
Implements: blueprint store-introspection-data
We'll soon have root_device_hints plugin, so it will become confusing.
Also added a test that we can use it under new name.
Change-Id: I049e049002cb25afc5aadb9a7a9e5d026a6810fd
* Add standard tas recognized by release-tools
* Stop mentioning Tuskar UI, as it's being refactored now
Change-Id: I18fc8f184376b0d643c53eb2928f5bb32662fb76
This test wasn't mocking socket, therefore was calling a real command out
to the test runners local network, which lead to unpredictable results.
This patch mocks and adds a sideeffect to the socket command to ensure
that it is behaving as expected for the test.
Change-Id: Ie9ab0a12c0d26ae4fa571941e181ebbf800b8ceb
It's the same as func, but runs functional tests with Python 3.
One issue was fixed in ironic_inspector.test.functional.
Change-Id: I6a081ad2ca8857018c6b531ed82182aab0ccca4d
Currently, Ironic Inspector talks with Swift using public API endpoint.
This patch fix this by making endpoint type configurable and also make
default value "internalURL".
Change-Id: Iab7d6a995d484bebb4338ffd307afcea132c0f20
Closes-Bug: #1470565
Add below procedure to periodic_clean_up() in order to sync data
with Ironic.
* Get Ironic's node list by executing python-ironicclient's node.list()
* Compare above Ironic-node-list and cache
* If node in cache is not exist in Ironic-node-list,
delete data from cache.
Change-Id: I606b0a76559b8bd2845d58146086b1019712dc34
Implements: blueprint delete-db-api
Without this it's hard to debug look up issues.
This change required NodeInfo to expose attributes.
Change-Id: Ieba14ab14dd356cc2c099656201c24fa46cbff6d