Skip to content

Conversation

@haseebsyed12
Copy link
Contributor

@haseebsyed12 haseebsyed12 commented Nov 19, 2025

Redfish inspection - should manipulate ports (create/update ports)
Agent inspection - should NOT manipulate ports (disable the ports hook)

Before:
[inspector]
default_hooks = ramdisk-error,validate-interfaces,ports,architecture
[redfish]
default_inspection_hooks = validate-interfaces,ports,architecture

After:
[inspector]
default_hooks = ramdisk-error,validate-interfaces,architecture
[redfish]
default_inspection_hooks = validate-interfaces,ports,architecture

@haseebsyed12 haseebsyed12 requested a review from a team November 19, 2025 13:23
@haseebsyed12 haseebsyed12 changed the title feat(ironic): Ironic to only manipulate ports during redfish inspection and not during agent inspection feat(ironic): manipulate ports only during redfish inspection and not during agent inspection Nov 19, 2025
redfish:
# Redfish inspection hooks - keep ports hook to allow port manipulation during redfish inspection
# Default hooks include: validate-interfaces,ports,architecture
inspection_hooks: "$default_inspection_hooks,pci-devices,parse-lldp,local-link-connection,resource-class"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a new block. I would drop this because its adding extra hooks for redfish.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So what you have in the PR description is what makes sense to me but that's not what's happening in the code. Dropping this block would make that match.

@haseebsyed12 haseebsyed12 force-pushed the skip-port-manipulation-agent-inspect branch from 0c3704a to f5de5aa Compare November 21, 2025 03:57
When using the agent inspect interface, prevent agent inspection from creating ports by removing "ports" from agent's default_hooks.
When using the redfish inspect interface, Redfish inspection creates ports directly through _create_ports() method called from inspect_hardware() method itself, not primarily through hooks.
@haseebsyed12 haseebsyed12 force-pushed the skip-port-manipulation-agent-inspect branch from f5de5aa to 36e9bce Compare November 21, 2025 04:02
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.

4 participants