Add more description to policies in the keypairs.py

This updates the policy doc for server extend controller in keypairs.py

Partial implement blueprint blueprint policy-docs

Change-Id: I32d2dae19fc2cfa99470edbb39dafd56de279b73
This commit is contained in:
He Jie Xu 2017-05-02 11:41:15 +08:00
parent c2d3e80658
commit 3052a451d1
1 changed files with 14 additions and 5 deletions

View File

@ -13,8 +13,6 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslo_policy import policy
from nova.policies import base
@ -63,9 +61,20 @@ keypairs_policies = [
'method': 'GET'
}
]),
policy.RuleDefault(
name=BASE_POLICY_NAME,
check_str=base.RULE_ADMIN_OR_OWNER),
base.create_rule_default(
BASE_POLICY_NAME,
base.RULE_ADMIN_OR_OWNER,
"Return 'key_name' in the response of server.",
[
{
'path': '/servers/{id}',
'method': 'GET',
},
{
'path': '/servers/detail',
'method': 'GET'
}
]),
]