Skip to content

Commit

Permalink
feat: add option to attach a permissions boundary
Browse files Browse the repository at this point in the history
It is now possible to attach a permissions boundary to
the cloudbench role.
  • Loading branch information
quentin-laplanche committed Aug 14, 2024
1 parent 220725f commit 92a76c2
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
7 changes: 4 additions & 3 deletions modules/services/cloud-bench/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,10 @@ data "aws_iam_policy_document" "trust_relationship" {
resource "aws_iam_role" "cloudbench_role" {
count = var.is_organizational && !var.provision_caller_account ? 0 : 1

name = var.name
assume_role_policy = data.aws_iam_policy_document.trust_relationship.json
tags = var.tags
name = var.name
assume_role_policy = data.aws_iam_policy_document.trust_relationship.json
tags = var.tags
permissions_boundary = var.permissions_boundary_arn
}


Expand Down
6 changes: 6 additions & 0 deletions modules/services/cloud-bench/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,9 @@ variable "tags" {
"product" = "sysdig-secure-for-cloud"
}
}

variable "permissions_boundary_arn" {
type = string
description = "ARN of a permissions boundary policy to attach to the cloudbench role"
default = null
}

0 comments on commit 92a76c2

Please sign in to comment.