def get_project_iam_policies(self, resource_name, project_id):
"""Get all the iam policies of given project numbers.
Args:
resource_name (str): The resource type.
project_id (str): Either the project number or the project id.
Returns:
list: IAM policies of the project.
https://cloud.google.com/resource-manager/reference/rest/Shared.Types/Policy
"""
try:
return self.repository.projects.get_iam_policy(project_id)
except (errors.HttpError, HttpLib2Error) as e:
raise api_errors.ApiExecutionError(resource_name, e)
cloud_resource_manager.py 文件源码
python
阅读 27
收藏 0
点赞 0
评论 0
评论列表
文章目录