Creating cert for alpha LB
This commit is contained in:
parent
687e6a173b
commit
5c025dad33
17
infra/acm.tf
17
infra/acm.tf
@ -3,7 +3,7 @@
|
||||
# alpha does not depend on this resource and thus is our problem
|
||||
|
||||
resource "aws_acm_certificate" "website" {
|
||||
domain_name = "temper.tv"
|
||||
domain_name = "*.temper.tv"
|
||||
subject_alternative_names = [ "temper.tv" ]
|
||||
validation_method = "DNS"
|
||||
|
||||
@ -12,3 +12,18 @@ resource "aws_acm_certificate" "website" {
|
||||
}
|
||||
}
|
||||
|
||||
resource "aws_route53_record" "website_cert_record" {
|
||||
for_each = {
|
||||
for dvo in aws_acm_certificate.website.domain_validation_options : dvo.domain_name => {
|
||||
name = dvo.resource_record_name
|
||||
record = dvo.resource_record_value
|
||||
type = dvo.resource_record_type
|
||||
}
|
||||
}
|
||||
name = each.value.name
|
||||
type = each.value.type
|
||||
records = [ each.value.record ]
|
||||
zone_id = aws_route53_zone.main.id
|
||||
ttl = 60
|
||||
}
|
||||
|
||||
|
@ -9,7 +9,7 @@ terraform {
|
||||
required_providers {
|
||||
aws = {
|
||||
source = "hashicorp/aws"
|
||||
version = ">= 5.0"
|
||||
version = "4.13.0"
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user