Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions etc/kayobe/kolla/config/horizon/_9999-custom-settings.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
SYSTEM_SCOPE_SERVICES = ['ironic']
2 changes: 1 addition & 1 deletion etc/kayobe/kolla/config/ironic/policy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
# GET /nodes/detail
# Intended scope(s): system, project
# Overridden: added role:admin
"baremetal:node:list_all": "role:admin or (role:reader and system_scope:all) or (role:service and system_scope:all) or rule:service_role"
"baremetal:node:list_all": "role:baremetal_node_list_all or (role:reader and system_scope:all) or (role:service and system_scope:all) or rule:service_role"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

does it mean that regular admin users now won't be able to list all baremetals from cli? - I think that was idea behind this policy override. also baremetal_node_list_all don't exist by default?

Copy link
Copy Markdown
Contributor Author

@jovial jovial Aug 18, 2025

Choose a reason for hiding this comment

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

baremetal_node_list_all don't exist by default?

Correct, you'd have to create that.

does it mean that regular admin users now won't be able to list all baremetals from cli?

Correct, unless they own all nodes (via setting the owner property on baremetal nodes). You can add the new role if you need that behaviour (but it will break your horizon).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Will this break Horizon, even with SYSTEM_SCOPE_SERVICES = ['ironic'] set?

Copy link
Copy Markdown
Contributor Author

@jovial jovial Sep 12, 2025

Choose a reason for hiding this comment

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

Yes, as I think system scope appears in the project drop down. So if you have a project selected (rather than system scope) and you navigate to the baremetal provisioning section, you will get a bunch of errors. You would be able to select system scope and browse to the same page though.

Copy link
Copy Markdown
Contributor

@JohnGarbutt JohnGarbutt Sep 26, 2025

Choose a reason for hiding this comment

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

@bbezak what I think we should do is make sure the nodes are all added into a single project, e.g. admin project, so the regular project scoped admin user can still list them all, and do all the usual actions to the nodes that worked in yoga, etc.

In my head, this extra role here is only needed to help in the Slurm case, where some other member in some other project, needs to list all baremetal nodes, to convert the baremetal node name into a uuid, to pass into the scheduler hint.

Copy link
Copy Markdown
Contributor Author

@jovial jovial May 21, 2026

Choose a reason for hiding this comment

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

I think John is right. We don't break horizion for ordinary users (non-admin). It is is breaking change for users with the admin role though - so perhaps best to merge in 2026.1?

Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
upgrade:
- |
Users with the admin role can no longer list all baremetal nodes by
default. Please assign any users that want this functionality the
``baremetal_node_list_all`` role.
- |
Fixes Horizon Ironic integration which was broken by custom policy.
Loading