Skip to content

feat: bump policies to new format + v2#3

Merged
gusfcarvalho merged 5 commits into
mainfrom
codex/update-cloudcustodian-policies
Apr 24, 2026
Merged

feat: bump policies to new format + v2#3
gusfcarvalho merged 5 commits into
mainfrom
codex/update-cloudcustodian-policies

Conversation

@gusfcarvalho
Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings April 23, 2026 17:51
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the Cloud Custodian compliance policy and its tests to use the new per-resource schema_version: v2 payload format, and introduces resource-deduped risk templates/labels aligned to that format.

Changes:

  • Migrates cloud_custodian_resources_detected policy logic from “resources array + execution errors” to per-resource assessment.status evaluation and adds risk_templates/labels.
  • Rewrites Rego tests to validate v2 payload behavior, including title/description formatting and resource display-name extraction from ARNs.
  • Updates README guidance to describe the v2 per-resource payload and dedupe labels.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
policies/cloud_custodian_resources_detected.rego Implements v2 per-resource evaluation, labels, and a risk template for deduped violations.
policies/cloud_custodian_resources_detected_test.rego Replaces legacy tests with v2 payload fixtures and assertions for violations, metadata, labels, and templates.
README.md Documents the v2 payload expectations and recommended dedupe labels.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/cloud_custodian_resources_detected.rego
Comment thread policies/cloud_custodian_resources_detected.rego Outdated
Comment thread README.md
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/cloud_custodian_resources_detected.rego Outdated
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/cloud_custodian_resources_detected.rego Outdated
Comment thread policies/cloud_custodian_resources_detected.rego Outdated
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread policies/cloud_custodian_resources_detected.rego
Comment thread README.md
Signed-off-by: Gustavo Carvalho <gustavo.carvalho@container-solutions.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@gusfcarvalho gusfcarvalho merged commit 0bd9235 into main Apr 24, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants