Conversation
WalkthroughThe change expands workload identity federation configuration to include the Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~5 minutes 🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@gcp/workload-identity-federation-direct.tf`:
- Line 37: The current attribute_condition on the Workload Identity Federation
provider (attribute_condition) only checks assertion.repository and combined
with the project-level grant of roles/aiplatform.user (the new role binding)
allows any run in ambient-code/pull-reviews to gain broad access; tighten the
condition to also require trusted refs and workflow identity (e.g., include
assertion.ref matching allowed branches/tags and assertion.job_workflow_ref or
assertion.workflow for specific workflow files) and update attribute_mapping to
map assertion.ref and assertion.job_workflow_ref (or assertion.workflow) so
those claims are available for evaluation; additionally, scope the
roles/aiplatform.user grant to the minimum resource (not project-level) or add
the stricter conditional using these mapped attributes to the IAM binding (the
binding that grants roles/aiplatform.user) to ensure only the intended
workflows/refs can assume the role.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
Run ID: 316b00bd-e6cd-4363-9abd-08ab3af6533e
📒 Files selected for processing (1)
gcp/workload-identity-federation-direct.tf
|
@syntaxsdev ambient-code/platform#949 adds this action to the |
No description provided.