From 7d3259ddd86234a0743cd9afb973ac522c7a125a Mon Sep 17 00:00:00 2001 From: Davanum Srinivas Date: Sun, 8 Nov 2015 21:47:57 -0500 Subject: [PATCH] Remove duplicate keys in policy.json In I8d58be7f3cb1bdefc3b783a256c21ed216cdbad7, we added "compute:delete", "compute:soft_delete" and "compute:force_delete", So let's remove the older lines that have the an empty "" target. Change-Id: I239ca596cca4631e311d7afe45de7ffcc60f70b9 --- etc/nova/policy.json | 3 --- nova/tests/unit/test_policy.py | 6 +++--- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/etc/nova/policy.json b/etc/nova/policy.json index 5f6023e5c3..129acfc7a4 100644 --- a/etc/nova/policy.json +++ b/etc/nova/policy.json @@ -85,9 +85,6 @@ "compute:security_groups:add_to_instance": "", "compute:security_groups:remove_from_instance": "", - "compute:delete": "", - "compute:soft_delete": "", - "compute:force_delete": "", "compute:restore": "", "compute:volume_snapshot_create": "", diff --git a/nova/tests/unit/test_policy.py b/nova/tests/unit/test_policy.py index a99f79a04c..249392e002 100644 --- a/nova/tests/unit/test_policy.py +++ b/nova/tests/unit/test_policy.py @@ -368,6 +368,9 @@ class RealRolePolicyTestCase(test.NoDBTestCase): "default", "compute:start", "compute:stop", +"compute:delete", +"compute:soft_delete", +"compute:force_delete", "compute_extension:admin_actions:pause", "compute_extension:admin_actions:unpause", "compute_extension:admin_actions:suspend", @@ -405,8 +408,6 @@ class RealRolePolicyTestCase(test.NoDBTestCase): "compute:create", "compute:create:attach_network", "compute:create:attach_volume", -"compute:delete", -"compute:force_delete", "compute:get_all_instance_metadata", "compute:get_all_instance_system_metadata", "compute:get_console_output", @@ -452,7 +453,6 @@ class RealRolePolicyTestCase(test.NoDBTestCase): "compute:security_groups:remove_from_instance", "compute:set_admin_password", "compute:snapshot", -"compute:soft_delete", "compute:suspend", "compute:swap_volume", "compute:unlock",