Last active
March 21, 2021 19:51
-
-
Save refayathaque/999546170efe381a6c9e2bc7e0f2df11 to your computer and use it in GitHub Desktop.
Part of "Automate hosting a static website on AWS with Terraform" post
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "aws_acm_certificate" "certificate" { | |
domain_name = var.DOMAIN_NAME | |
validation_method = "DNS" | |
lifecycle { | |
create_before_destroy = true | |
} | |
} | |
resource "aws_acm_certificate_validation" "certificate" { | |
certificate_arn = aws_acm_certificate.certificate.arn | |
validation_record_fqdns = [for record in aws_route53_record.certificate_validation : record.fqdn] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment