Skip to content

SAAS-29781 - Split CSPM Role to Registry and Serverless Roles (Single/Org)#22

Merged
idanch4 merged 3 commits intomainfrom
idan-SAAS-29781-add-registry-serverless-roles
Oct 21, 2025
Merged

SAAS-29781 - Split CSPM Role to Registry and Serverless Roles (Single/Org)#22
idanch4 merged 3 commits intomainfrom
idan-SAAS-29781-add-registry-serverless-roles

Conversation

@idanch4
Copy link
Copy Markdown
Contributor

@idanch4 idanch4 commented Oct 14, 2025

Note

Introduce Registry (ECR) and Serverless (Lambda) scanning with separate IAM roles, end-to-end wiring, validations, and docs updates.

  • Terraform modules:
    • Single/Organization:
      • Add inputs/toggles: registry_scanning_deployment, serverless_scanning_deployment, custom_registry_scanning_role_name, custom_serverless_scanning_role_name, and pass through to submodules.
      • Organization StackSet parameters include BaseCSPM, GroupId, and new scanning toggles/role names.
    • Lambda (single):
      • Create new IAM roles: aws_iam_role.registry_scanning_role and aws_iam_role.serverless_scanning_role (conditional on toggles).
      • Expose outputs: registry_scanning_role_arn, serverless_scanning_role_arn.
    • Trigger (single):
      • Extend trigger-aws.py and trigger.tf to send registry_scanning_deployment, serverless_scanning_deployment, and role ARNs in discovery payload.
  • Variables/validations:
    • Root and organization: add validations for volume_scanning_deployment and new toggles; define custom role name vars with length/charset checks; add aqua_cspm_group_id.
  • Outputs:
    • Surface new role ARNs from modules/single.
  • Docs:
    • README inputs updated with new variables and toggles.

Written by Cursor Bugbot for commit 264cd92. This will update automatically on new commits. Configure here.

Split CSPM IAM role into separate optional roles for registry and serverless scanning. Roles default to enabled for backward compatibility.
…ation Deployment

Add missing parameters for registry and serverless scanning to organization deployment:
- Add registry_scanning_deployment and serverless_scanning_deployment variables
- Add custom_registry_scanning_role_name and custom_serverless_scanning_role_name variables
- Add base_cspm and aqua_cspm_group_id variables to organization module
- Forward all parameters to CloudFormation stack with correct parameter names
- Add consistent validation for all new variables
- Ensure backward compatibility with default values (enabled by default)

Organization deployment now has full parity with single account deployment for registry and serverless scanning functionality.
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Oct 14, 2025

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
0 out of 2 committers have signed the CLA.

❌ Idan Chernihov
❌ github-actions[bot]


Idan Chernihov seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@github-actions
Copy link
Copy Markdown
Contributor

Terraform Validation Results:

Terraform Format Check ✅
Terraform Init ✅
Terraform Validate ✅
Terraform Test ✅
TFLint Check ✅

Pusher: @idanch4, Action: pull_request, Workflow: PR Checks

@idanch4 idanch4 changed the title SAAS-29781 - Split CSPM Role to Registry Serverless Role (Single/Org) SAAS-29781 - Split CSPM Role to Registry and Serverless Roles (Single/Org) Oct 14, 2025
@idanch4 idanch4 marked this pull request as ready for review October 19, 2025 11:21
@idanch4 idanch4 merged commit 5ac45af into main Oct 21, 2025
1 of 2 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.

4 participants