[agw-cuj-arun-egress-vpc] - missing IAM grants for Agent Gateway service agent

未关闭 适合新手
#2,397 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
72/100
Issue 类型
文档
描述清晰度
描述清楚
活跃度
活跃
技术栈
google-cloud

调研方向

打开链接的 Agent Gateway egress codelab,并检查第 4 步、第 5 步和第 1 部分的 API 批次。确认报告的 IAM 授权应放在第 4 步末尾,并从批次中移除 iamconnectors.googleapis.com。完成标准是:codelab 在导入网关之前包含这些授权,且其余 API 无需这个不可用的服务即可启用。

由索引模型根据 Issue 内容生成。

描述

Codelab: Agent Gateway egress from Agent Runtime to VPC network

Thanks for this awesome lab!

Context: fresh project, first time using Agent Gateway, Agent Registry and Agent Runtime. None of these APIs or roles had been enabled or granted before the codelab. Once granted, the roles persist (step 14 does not remove them), so a second run in the same project does not show these errors.

5. Gateway - import fails

gcloud network-services agent-gateways import fails with Config validation failed. The Agent Gateway service agent cannot read the VPC network, the PSC network attachment or the Cloud DNS zones. Single project, steps run as written.

does not have permission to read target network ... grant it roles/compute.networkViewer
does not have permission to read network attachment ... (compute.networkAttachments.get)
does not have permission to list Cloud DNS managed zones ... grant roles/dns.reader in the project

Fix: add to the end of step 4, so IAM propagates before step 5.

# grant compute network viewer to agent gateway service agent
gcloud projects add-iam-policy-binding ${PROJ_ID} \
  --member="serviceAccount:service-${PROJ_NO}@gcp-sa-agentgateway.iam.gserviceaccount.com" \
  --role="roles/compute.networkViewer" \
  --condition=None

# grant dns reader to agent gateway service agent
gcloud projects add-iam-policy-binding ${PROJ_ID} \
  --member="serviceAccount:service-${PROJ_NO}@gcp-sa-agentgateway.iam.gserviceaccount.com" \
  --role="roles/dns.reader" \
  --condition=None

3. Setup - API batch fails

iamconnectors.googleapis.com is not available to projects outside its allowlist. With it included, the whole part 1 batch fails and the other APIs in it (agentregistry, aiplatform, networkservices and others) are not enabled.

Service iamconnectors.googleapis.com is not available to this consumer.

Fix: remove iamconnectors.googleapis.com from part 1 and re-run. The rest of part 1 then enables. No later step uses it.

主要语言
没有语言数据
星标
32
派生
65
PR 合并指标
30 天内没有已合并 PR

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

googlecodelabs/feedback 的其他 Issue

查看 googlecodelabs/feedback 的全部 Issue

相似的 Issue

更多 Cloud Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。