Google Cloud Role访问特定的发布/订阅主题 [英] Google Cloud Role to access specific pub/sub topic

查看:61
本文介绍了Google Cloud Role访问特定的发布/订阅主题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以通过指定角色来允许您收听非常特定的发布/订阅主题而不是全部主题?

Is it possible to specify a Role in such a way that it allows you to listen to a very specific Pub/Sub topic rather than all of them?

推荐答案

角色适用于资源,因此最适当的问题是可以将策略设置为发布/订阅资源吗?"

Roles apply to a resource, so the most adequate question would be "Can a policy be set into a Pub/Sub resource?"

答案是肯定的,并且通过Pub/Sub API方法完成 projects.topics.setIamPolicy .对于该端点,您必须通过政策,该政策将允许您为角色 Owner Editor Viewer 设置绑定.

The answer is yes, and it's done through the Pub/Sub API method projects.topics.setIamPolicy. To that endpoint, you must pass a policy, which will allow you to set bindings for the roles Owner, Editor, or Viewer.

这篇关于Google Cloud Role访问特定的发布/订阅主题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆