本文整理匯總了Python中archipelcore.archipelEntity.TNArchipelEntity.init_permissions方法的典型用法代碼示例。如果您正苦於以下問題:Python TNArchipelEntity.init_permissions方法的具體用法?Python TNArchipelEntity.init_permissions怎麽用?Python TNArchipelEntity.init_permissions使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類archipelcore.archipelEntity.TNArchipelEntity
的用法示例。
在下文中一共展示了TNArchipelEntity.init_permissions方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: init_permissions
# 需要導入模塊: from archipelcore.archipelEntity import TNArchipelEntity [as 別名]
# 或者: from archipelcore.archipelEntity.TNArchipelEntity import init_permissions [as 別名]
def init_permissions(self):
"""
Initialize the permissions.
"""
TNArchipelEntity.init_permissions(self)
self.permission_center.create_permission("alloc", "Authorizes users to allocate new virtual machines", False)
self.permission_center.create_permission("free", "Authorizes users to free allocated virtual machines", False)
self.permission_center.create_permission("rostervm", "Authorizes users to access the hypervisor's roster", False)
self.permission_center.create_permission("clone", "Authorizes users to clone virtual machines", False)
self.permission_center.create_permission("ip", "Authorizes users to get hypervisor's IP address", False)
self.permission_center.create_permission("uri", "Authorizes users to get the hypervisor's libvirt URI", False)
self.permission_center.create_permission("capabilities", "Authorizes users to access the hypervisor capabilities", False)
示例2: init_permissions
# 需要導入模塊: from archipelcore.archipelEntity import TNArchipelEntity [as 別名]
# 或者: from archipelcore.archipelEntity.TNArchipelEntity import init_permissions [as 別名]
def init_permissions(self):
"""
Initialize the permissions.
"""
TNArchipelEntity.init_permissions(self)
self.permission_center.create_permission("alloc", "Authorizes users to allocate new virtual machines", False)
self.permission_center.create_permission("free", "Authorizes users to free allocated virtual machines", False)
self.permission_center.create_permission("rostervm", "Authorizes users to access the hypervisor's roster", False)
self.permission_center.create_permission("clone", "Authorizes users to clone virtual machines", False)
self.permission_center.create_permission("ip", "Authorizes users to get hypervisor's IP address", False)
self.permission_center.create_permission("migrationinfo", "Authorizes users to get the migration informations", False)
self.permission_center.create_permission("capabilities", "Authorizes users to access the hypervisor capabilities", False)
self.permission_center.create_permission("manage", "Authorizes users make Archipel able to manage external virtual machines", False)
self.permission_center.create_permission("unmanage", "Authorizes users to make Archipel able to unmanage virtual machines", False)
示例3: init_permissions
# 需要導入模塊: from archipelcore.archipelEntity import TNArchipelEntity [as 別名]
# 或者: from archipelcore.archipelEntity.TNArchipelEntity import init_permissions [as 別名]
def init_permissions(self):
"""
Initialize the permissions.
"""
TNArchipelEntity.init_permissions(self)