Skip to content

oowlish/terraform-aws-uploads-bucket

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Terraform AWS Uploads Bucket (S3 Bucket + CloudFront Distribution)

Usage

data "aws_acm_certificate" "example" {
  domain   = "*.example.com"
  statuses = ["ISSUED"]
}

module "example_uploads" {
  source = "github.com/oowlish/terraform-aws-uploads-bucket?ref=master"

  name = "example"

  s3_allowed_roles   = ["arn:aws:iam::999999999999:role/SomeSpecificRole"]
  s3_forbidden_files = ["**/*.php"]
  
  cloudfront_aliases             = ["uploads.example.com"]
  cloudfront_price_class         = "PriceClass_All"
  cloudfront_acm_certificate_arn = data.aws_acm_certificate.arn

  tags = {
    Terraform = "true
  }
}

Requirements

Name Version
terraform ~> 0.12

Inputs

Name Description Type Default Required
cloudfront_acm_certificate_arn The ARN of the AWS Certificate Manager certificate that you wish to use with this distribution. The ACM certificate must be in US-EAST-1. string "" no
cloudfront_aliases CNAMEs for this CloudFront. list(string) n/a yes
cloudfront_price_class The price class for this CloudFront. One of PriceClass_All, PriceClass_200, PriceClass_100. string "PriceClass_100" no
name Name to be used on all the resources as identifier. string n/a yes
s3_allowed_roles A list IAM roles allowed to access the S3 bucket. list(string) [] no
s3_forbidden_files A list of file to deny access for. list(string) [] no
tags A map of tags to assign to the resources. map(string) {} no

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages