cloudfront-s3-cdn
cloudposse/cloudfront-s3-cdn/aws
Terraform module to easily provision CloudFront CDN backed by an S3 origin
Terraform module to provision an AWS CloudFront CDN with an S3 origin. > [!TIP] > #### 👽 Use Atmos with Terraform > Cloud Posse uses atmos to easily orchestrate multiple environments using Terraform. > Works with Github Actions, Atlantis, or Spacelift. > > > Watch demo of using Atmos with Terraform > > Example of running atmos to manage infrastructure from our Quick Start tutorial. > Usage For a complete example, see examples/complete. For automated tests of the complete example using bats and Terratest (which tests and deploys the example on AWS), see test. The following will create a new s3 bucket eg-prod-app for a cloudfront cdn, and allow principal1 to upload to prefix1 and prefix2, while allowing principal2 to manage the whole bucket. ```hcl module "cdn" { source = "cloudposse/cloudfr
| Name | Type | Description | Default |
|---|---|---|---|
| realtime_log_config_arn | string | The ARN of the real-time log configuration that is attached to this cache behavi | null |
| cors_allowed_methods | list(string) | List of allowed methods (e.g. GET, PUT, POST, DELETE, HEAD) for S3 bucket | [
"GET"
] |
| parent_zone_id | string | ID of the hosted zone to contain this record (or specify `parent_zone_name`). Re | null |
| dns_alias_enabled | bool | Create a DNS alias for the CDN. Requires `parent_zone_id` or `parent_zone_name` | false |
| name | string | ID element. Usually the component or solution name, e.g. 'app' or 'jenkins'. Thi | null |
| custom_origins | list(object({ domain_name | A list of additional custom website [origins](https://www.terraform.io/docs/prov | [] |
| s3_access_log_prefix | string | Prefix to use for S3 Access Log object keys. Defaults to `logs/${module.this.id} | "" |
| regex_replace_chars | string | Terraform regular expression (regex) string. Characters matching the regex will | null |
| origin_bucket | string | Name of an existing S3 bucket to use as the origin. If this is not provided, it | null |
| forward_header_values | list(string) | A list of whitelisted header values to forward to the origin (incompatible with | [
"Access-Control-Request-Headers",
|
| function_association | list(object({ event_type | A config block that triggers a CloudFront function with specific actions. See th | [] |
| extra_origin_attributes | list(string) | Additional attributes to put onto the origin label | [
"origin"
] |
| minimum_protocol_version | string | Cloudfront TLS minimum protocol version. If `var.acm_certificate_arn` is unset, | "" |
| viewer_protocol_policy | string | Limit the protocol users can use to access content. One of `allow-all`, `https-o | "redirect-to-https" |
| trusted_signers | list(string) | The AWS accounts, if any, that you want to allow to create signed URLs for priva | [] |
| environment | string | ID element. Usually used for region e.g. 'uw2', 'us-west-2', OR role 'prod', 'st | null |
| cached_methods | list(string) | List of cached methods (e.g. GET, PUT, POST, DELETE, HEAD) | [
"GET",
"HEAD"
] |
| max_ttl | number | Maximum amount of time (in seconds) that an object is in a CloudFront cache | 31536000 |
| trusted_key_groups | list(string) | A list of key group IDs that CloudFront can use to validate signed URLs or signe | [] |
| enabled | bool | Set to false to prevent the module from creating any resources | null |
| … and 10 more inputs | |||
logs — Log bucket resourcecf_status — Current status of the distributioncf_etag — Current version of the distribution's informationcf_origin_groups — List of Origin Groups in the CloudFront distribution.cf_origin_ids — List of Origin IDs in the CloudFront distribution.aliases — Aliases of the CloudFront distribution.cf_id — ID of AWS CloudFront distributioncf_identity_iam_arn — CloudFront Origin Access Identity IAM ARNcf_access_control_id — CloudFront Origin Access Control IDcf_primary_origin_id — The ID of the origin created by this module.s3_bucket_arn — ARN of origin S3 buckets3_bucket_domain_name — Domain of origin S3 bucketcf_arn — ARN of AWS CloudFront distributioncf_domain_name — Domain name corresponding to the distributioncf_hosted_zone_id — CloudFront Route 53 zone IDs3_bucket — Name of origin S3 bucketcf_s3_canonical_user_id — Canonical user ID for CloudFront Origin Access Identitys3_bucket_policy — Final computed S3 bucket policyAzure landing zones Terraform module
Terraform supermodule for the Terraform platform engineering for Azure
Terraform module to deploy landing zone subscriptions (and much more) in Azure
Terraform Module to define a consistent naming convention by (namespace, stage,