Skip to content

Commit

Permalink
fix: Use source role for ecr access (#180)
Browse files Browse the repository at this point in the history
  • Loading branch information
mailo-nr authored Jan 9, 2025
1 parent 6fa9ac5 commit f5f4bce
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion test/terraform/permanent/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,18 @@ resource "helm_release" "ci_e2e_nightly" {

data "aws_caller_identity" "current" {}

data "aws_iam_session_context" "current" {
arn = data.aws_caller_identity.current.arn
}

module "ecr" {
depends_on = [module.ci_e2e_cluster]

source = "terraform-aws-modules/ecr/aws"

repository_name = "nr-otel-collector"

repository_read_write_access_arns = [data.aws_caller_identity.current.arn]
repository_read_write_access_arns = [data.aws_iam_session_context.current.issuer_arn]
repository_read_access_arns = [module.ci_e2e_cluster.cluster_iam_role_arn]

repository_lifecycle_policy = jsonencode({
Expand Down

0 comments on commit f5f4bce

Please sign in to comment.