Skip to content

Commit

Permalink
Merge pull request #16 from nuuday/terraform-0.15-upgrade
Browse files Browse the repository at this point in the history
chore: upgrade s3 bucket module to make it compatible with terraform 0.15
  • Loading branch information
jsnns-nuuday authored May 3, 2021
2 parents b3ad203 + 0a4fd71 commit 08c693c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ locals {
namespace = var.namespace
repository = "https://grafana.github.io/helm-charts"
bucket_prefix = "grafana"
bucket_name = module.s3_bucket.this_s3_bucket_id
bucket_name = module.s3_bucket.s3_bucket_id
role_name = local.bucket_name
provider_url = replace(var.oidc_provider_issuer_url, "https://", "")

Expand Down Expand Up @@ -52,7 +52,7 @@ locals {

"external_image_storage.s3" = {
bucket = local.bucket_name
region = module.s3_bucket.this_s3_bucket_region
region = module.s3_bucket.s3_bucket_region
}
}

Expand Down Expand Up @@ -117,7 +117,7 @@ data "aws_iam_policy_document" "grafana" {
"s3:GetObject"
]

resources = [module.s3_bucket.this_s3_bucket_arn, "${module.s3_bucket.this_s3_bucket_arn}/*"]
resources = [module.s3_bucket.s3_bucket_arn, "${module.s3_bucket.s3_bucket_arn}/*"]
}
}

Expand All @@ -136,7 +136,7 @@ resource "aws_iam_role_policy_attachment" "additional" {
}

module "s3_bucket" {
source = "github.com/terraform-aws-modules/terraform-aws-s3-bucket?ref=v1.17.0"
source = "github.com/terraform-aws-modules/terraform-aws-s3-bucket?ref=v2.0.0"

bucket_prefix = local.bucket_prefix
acl = "private"
Expand Down

0 comments on commit 08c693c

Please sign in to comment.