yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #73015
[Bug 1772759] Re: Horizon checks wrong policy rule for attach_volume
based on
https://git.openstack.org/cgit/openstack/nova/tree/nova/policies/volumes_attachments.py
I think I need to switch to "os_compute_api:os-volumes-
attachments:create": "rule:admin_or_owner" (and the corresponding delete
for detach), I'll reopen the bug and post a new commit
** Changed in: horizon
Status: Fix Released => In Progress
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1772759
Title:
Horizon checks wrong policy rule for attach_volume
Status in OpenStack Dashboard (Horizon):
In Progress
Bug description:
The instances table in Horizon checks for policy rule
"os_compute_api:servers:attach_volume" (see:
https://git.openstack.org/cgit/openstack/horizon/tree/openstack_dashboard/dashboards/project/instances/tables.py#n895
), but this rule doesn't exist in the default policy file (
https://git.openstack.org/cgit/openstack/horizon/tree/openstack_dashboard/conf/nova_policy.json?h=master
) or in Novas own source or tests.
Instead, the rule "os_compute_api:servers:create:attach_volume" is
used...
In the policy file:
https://git.openstack.org/cgit/openstack/horizon/tree/openstack_dashboard/conf/nova_policy.json?h=master#n138
And in Novas unit tests:
https://git.openstack.org/cgit/openstack/nova/tree/nova/tests/unit/api/openstack/compute/test_serversV21.py#n5414
Generating a policy file from Nova using the oslo policy generator (
https://docs.openstack.org/horizon/latest/contributor/topics/policy.html
) has the same results, the output file includes a rule of
"os_compute_api:servers:create:attach_volume" but *NOT* of
"os_compute_api:servers:attach_volume" . The net result is that using
the default policy file, or an unmodified generated policy file,
results in the "attach volume" option missing from the Compute
Instances menu.
To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1772759/+subscriptions
References