cloudfront_static_site_custom_error_responses |
CloudFront Static Site custom error responses |
map(object({ response_code = string response_page_path = string })) |
{ "404": { "response_code": "404", "response_page_path": "/404.html" } } |
no |
cloudfront_static_site_default_cache_behaviour |
Default cache behaviour block for the Static Site CloudFront Distribution |
object({ allowed_methods = optional(list(string), ["GET", "HEAD"]) cached_methods = optional(list(string), ["GET", "HEAD"]) cache_policy_id = optional(string, null) compress = optional(bool, true) default_ttl = optional(number, 0) lambda_function_associations = optional(map(object({ event_type = string lambda_arn = string include_body = optional(bool, false) })), {}) function_associations = optional(map(object({ event_type = string function_arn = string })), {}) max_ttl = optional(number, 31536000) min_ttl = optional(number, 1) origin_request_policy_id = optional(string, null) realtime_log_config_arn = optional(string, null) response_headers_policy_id = optional(string, null) smooth_streaming = optional(bool, false) trusted_signers = optional(list(string), null) viewer_protocol_policy = optional(string, "redirect-to-https") }) |
{} |
no |
cloudfront_static_site_default_root_object |
CloudFront Static Site default root object |
string |
"index.html" |
no |
cloudfront_static_site_http_version |
CloudFront Static Site http version |
string |
"http2" |
no |
cloudfront_static_site_is_ipv6_enabled |
CloudFront Static Site enable ipv6 |
bool |
true |
no |
cloudfront_static_site_price_class |
CloudFront Static Site price class |
string |
"PriceClass_100" |
no |
cloudfront_static_site_restrictions |
Cloudfront Static Site restrictions block |
object({ geo_restriction = optional(object({ restriction_type = string locations = list(string) })) }) |
{ "geo_restriction": { "locations": [], "restriction_type": "none" } } |
no |
cloudfront_static_site_tls_certificate_arn |
CloudFront static site TLS Certificate ARN. This is not required, as one will be created based on the site_url . Use this only if the created certificate is not sufficient. |
string |
"" |
no |
cloudfront_static_site_web_acl_id |
CloudFront static site Web ACL id |
string |
null |
no |
enable_cloudfront |
Enable creation of CloudFront Distribution |
bool |
true |
no |
enable_cloudfront_static_site_logs |
Enable CloudFront Staci Site logging to the logs bucket |
bool |
true |
no |
enable_s3_access_logs |
Enable S3 access logs |
bool |
true |
no |
project_name |
Project Name |
string |
n/a |
yes |
route53_zone_id |
Route53 zone id. If provided, the certificate validation records and site records will be created in that zone |
string |
"" |
no |
s3_logs_force_destroy |
Force destroy Logs S3 bucket |
bool |
false |
no |
s3_static_site_force_destroy |
Force destroy Static Site S3 bucket |
bool |
false |
no |
site_host_name |
Site Host Name. This will be used for Certificate generation and CloudFront aliases |
string |
"" |
no |
site_redirect_to_www |
Conditionally redirect to www.<site_host_name> |
bool |
false |
no |
static_site_s3_acl |
Static Site S3 ACL |
string |
"private" |
no |
static_site_s3_enable_encryption |
Static Site S3 Enable Encyption |
bool |
true |
no |