Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: refactor ironic node create/update and setting of interfaces #194

Merged
merged 6 commits into from
Aug 5, 2024

Conversation

cardoe
Copy link
Contributor

@cardoe cardoe commented Aug 2, 2024

Refactored the create/update of the ironic node from the Nautobot data. Include code to adjust how we ensure that the driver and interfaces are set correctly. This partially grows out of #168 but doesn't include the full driver detection from Nautobot.

@cardoe cardoe marked this pull request as ready for review August 5, 2024 16:42
@cardoe cardoe requested a review from a team August 5, 2024 16:42
cardoe added 6 commits August 5, 2024 12:36
Added a common from argo event parser for the IronicNodeConfiguration
class and create tests with a sample event. Utilize this event parser to
create the node in ironic. The code follows the python-ironicclient a
little bit more closely here.
If we're working with an iDRAC based interface then we need to use the
Ironic idrac driver, otherwise use the redfish based driver. this
integrates some of the behaviors of #168. The communication with
Nautobot is going to ultimately be the best approach. But the
configuration of the Ironic side is better in this code.
When our nodes are in the manage state, we need to update their data as
well since we'll only be bringing nodes back to the manage state to make
changes to them.
Set the BMC username and password using the helper function from
ironicclient instead of having our own.
Drop another function local to the obm function and use the shared copy.
@cardoe cardoe merged commit 32909e2 into main Aug 5, 2024
12 checks passed
@cardoe cardoe deleted the event-node branch August 5, 2024 18:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants