Skip to content

Commit 40dce2c

Browse files
author
Sohan
committed
add subject_alternative_names option
1 parent 9088f34 commit 40dce2c

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

main.tf

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,10 @@ resource "aws_acm_certificate" "import-cert" {
3838
resource "aws_acm_certificate" "cert" {
3939
count = var.enable_acm_certificate && var.enable_aws_certificate ? 1 : 0
4040

41-
domain_name = var.domain_name
42-
validation_method = var.validation_method
43-
tags = module.labels.tags
41+
domain_name = var.domain_name
42+
validation_method = var.validation_method
43+
subject_alternative_names = var.subject_alternative_names
44+
tags = module.labels.tags
4445
lifecycle {
4546
create_before_destroy = true
4647
}

variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,12 @@ variable "domain_name" {
5050
description = "A domain name for which the certificate should be issued."
5151
}
5252

53+
variable "subject_alternative_names" {
54+
type = list(any)
55+
default = []
56+
description = "Set of domains that should be SANs in the issued certificate. To remove all elements of a previously configured list, set this value equal to an empty list ([]) or use the terraform taint command to trigger recreation."
57+
}
58+
5359
variable "validation_method" {
5460
type = string
5561
default = ""

0 commit comments

Comments
 (0)