How to kwow if a given role id is the admin role?
Hi, seems trivial but... How to kwow if a given role id is the admin role ? Matching on the 'admin' string ? Is there a function to check this ?
I use the keystone_client so I can easily get the role name from the role_id. I prefer not to match strings "admin" and use the policy method as explained here : http://docs.openstack.org/developer/h... But the syntax is not as simple I tried something like this :
credentials = {'roles':['admin']} is_admin = policy.check(credentials, 'admin_required', {})