Skip to content

Commit

Permalink
Merge pull request #28 from babbel/unify-variables
Browse files Browse the repository at this point in the history
Unify structure of module variables
  • Loading branch information
jansiwy authored Sep 23, 2024
2 parents 41a38eb + 86fc2f4 commit 4e6303a
Showing 1 changed file with 21 additions and 10 deletions.
31 changes: 21 additions & 10 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ EOS
variable "bucket_name" {
type = string

description = "Name of the S3 bucket to create"
description = <<EOS
Name of the S3 bucket to create.
EOS
}

variable "custom_error_response" {
Expand All @@ -53,31 +55,38 @@ variable "custom_error_response" {
response_page_path = string
})
)

default = []

description = "One or more custom error response elements to be used for the CloudFront distribution"
description = <<EOS
One or more custom error response elements to be used for the CloudFront distribution.
EOS
}

variable "default_root_object" {
type = string
default = null

description = "The default root object CloudFront is to request from the S3 bucket as root URL"
description = <<EOS
The default root object CloudFront is to request from the S3 bucket as root URL.
EOS
}

variable "http_version" {
type = string
default = "http2"

description = "Supported HTTP versions set on the CloudFront distribution"
description = <<EOS
Supported HTTP versions set on the CloudFront distribution.
EOS
}

variable "tags" {
type = map(string)
default = {}

description = "Tags to be assigned to the S3 bucket and the CloudFront distribution"
description = <<EOS
Map of tags assigned to all AWS resources created by this module.
EOS
}


Expand All @@ -87,10 +96,11 @@ variable "trusted_key_groups" {
id = string
})
)

default = null

description = "List of AWS Key Groups to trust for CloudFront distribution's default cache behavior"
description = <<EOS
List of AWS Key Groups to trust for CloudFront distribution's default cache behavior.
EOS
}

variable "ttl" {
Expand All @@ -99,12 +109,13 @@ variable "ttl" {
default = number
max = number
})

default = {
min = 0
default = 86400
max = 31536000
}

description = "The min, default and max TTLs set on the CloudFront distribution"
description = <<EOS
The min, default and max TTLs set on the CloudFront distribution.
EOS
}

0 comments on commit 4e6303a

Please sign in to comment.