Skip to content

Commit

Permalink
create capability to retrieve roles using keystone extension
Browse files Browse the repository at this point in the history
  • Loading branch information
sleepsonthefloor committed Sep 23, 2011
1 parent b3481d2 commit 75b1563
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
2 changes: 2 additions & 0 deletions openstackx/extras/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
from openstackx.extras.users import UserManager
from openstackx.extras.usage import UsageManager
from openstackx.extras.role_refs import RoleRefManager
from openstackx.extras.roles import RoleManager
from openstackx.extras.endpoint_templates import EndpointTemplateManager
from openstackx.extras.endpoints import EndpointManager
from openstackx.extras.security_groups import SecurityGroupManager
Expand Down Expand Up @@ -94,6 +95,7 @@ def __init__(self, **kwargs):
self.tenants = TenantManager(self)
self.users = UserManager(self)
self.role_refs = RoleRefManager(self)
self.roles = RoleManager(self)
self.endpoint_templates = EndpointTemplateManager(self)
self.endpoints = EndpointManager(self)

Expand Down
12 changes: 12 additions & 0 deletions openstackx/extras/roles.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
from openstackx.api import base


class Role(base.Resource):
pass


class RoleManager(base.ManagerWithFind):
resource_class = Role

def list(self):
return self._list("/OS-KSADM/roles", "roles")

0 comments on commit 75b1563

Please sign in to comment.