Skip to content

Commit

Permalink
Update main.tf
Browse files Browse the repository at this point in the history
Co-authored-by: Matt Gowie  <matt@masterpoint.io>
  • Loading branch information
kpankonen and Gowiem authored May 18, 2023
1 parent 81fb33e commit c5a82a6
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -186,22 +186,6 @@ data "aws_iam_policy_document" "resource_push_access" {
]
}

dynamic "statement" {
for_each = length(var.principals_lambda) > 0 ? [1] : []

content {
sid = "LambdaECRImageCrossAccountRetrievalPolicy"
effect = "Allow"
actions = [
"ecr:BatchGetImage",
"ecr:GetDownloadUrlForLayer"
]

principals {
type = "Service"
identifiers = ["lambda.amazonaws.com"]
}

condition {
test = "StringLike"
values = formatlist("arn:%s:lambda:*:%s:function:*", data.aws_partition.current.partition, var.principals_lambda)
Expand Down

0 comments on commit c5a82a6

Please sign in to comment.