Mint the observability collector check's identity token with the auth action, so the check runs after a deploy

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

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
83/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
gcp, github-actions, python
领域
ci-cd, cloud

调研方向

从.github/workflows/deploy-observability-collector.yml开始,查看部署步骤如何将凭据传递给verify_observability_collector.sh。查阅google-github-actions/auth@v2 action 的文档,了解其 ID token 输出,并将其与脚本接收 token 的方式进行比较。当部署后验证能够为 collector URL 签发并使用 token,随后完成数据摄取和日志拒绝检查时,工作即告完成。

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

描述

What happens

The "Deploy observability collector" workflow (.github/workflows/deploy-observability-collector.yml) has failed on all six of its runs since it began deploying automatically on 6 October 2026. Each run deployed a new collector revision, which now serves traffic, and then failed at "Verify Google Cloud ingestion and log rejection" with:

ERROR: (gcloud.auth.print-identity-token) Invalid account type for --audiences. Requires valid service account.

verify_observability_collector.sh gets the token it calls the collector with from gcloud auth print-identity-token --audiences=<collector URL>. The workflow signs in with workload identity federation (google-github-actions/auth@v2 with a workload identity provider and service account), and gcloud can't mint an identity token with an audience from that kind of credential. So the check that the deployed collector accepts traces and metrics, delivers them to Cloud Trace and Cloud Monitoring and rejects logs has never run after a deploy.

Expected

A second google-github-actions/auth@v2 step, after the deploy, mints the identity token for the deployed collector's URL (token_format: id_token), and the verification step reads it from that step's output. The workflow's existing permissions cover this: the GitHub workload identity can get identity tokens for the deploy service account, which can invoke the collector.

主要语言
Python
星标
18
派生
33
平均合并
2 天 10 小时
30 天内合并 PR
124

环境准备

从这里开始

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

PolicyEngine/policyengine-api 的其他 Issue

查看 PolicyEngine/policyengine-api 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

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