-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathacm.tf
More file actions
85 lines (70 loc) · 2.64 KB
/
Copy pathacm.tf
File metadata and controls
85 lines (70 loc) · 2.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
module "acm_request_certificate" {
source = "cloudposse/acm-request-certificate/aws"
version = "0.16.3"
providers = {
aws = aws.us-east-1
}
domain_name = var.cdn_domain_name
process_domain_validation_options = true
zone_id = data.aws_route53_zone.external.id
zone_name = data.aws_route53_zone.external.name
ttl = "300"
}
module "backend_acm_request_certificate" {
source = "cloudposse/acm-request-certificate/aws"
version = "0.16.3"
domain_name = var.backend_domain_name
process_domain_validation_options = true
zone_id = data.aws_route53_zone.external.id
zone_name = data.aws_route53_zone.external.name
ttl = "300"
}
module "landing_acm_request_certificate" {
source = "cloudposse/acm-request-certificate/aws"
version = "0.16.3"
providers = {
aws = aws.us-east-1
}
domain_name = var.landing_dns_name
process_domain_validation_options = true
zone_id = data.aws_route53_zone.landing_zone.id
zone_name = data.aws_route53_zone.landing_zone.name
ttl = "300"
}
module "facility_cdn_request_certificate" {
source = "cloudposse/acm-request-certificate/aws"
version = "0.16.3"
providers = {
aws = aws.us-east-1
}
domain_name = var.facility_cdn_name
process_domain_validation_options = true
zone_id = data.aws_route53_zone.external.id
zone_name = data.aws_route53_zone.external.name
ttl = "300"
}
# Connect LB to DNS Record
resource "aws_route53_record" "cname_route53_record" {
zone_id = data.aws_route53_zone.external.id
name = var.backend_domain_name
type = "CNAME"
ttl = "60"
records = [module.backend_alb.lb_dns_name]
}
# Metabase
module "metabase_acm_request_certificate" {
source = "cloudposse/acm-request-certificate/aws"
version = "0.16.3"
domain_name = var.metabase_domain_name
process_domain_validation_options = true
zone_id = data.aws_route53_zone.external.id
zone_name = data.aws_route53_zone.external.name
ttl = "300"
}
resource "aws_route53_record" "metabase_cname_route53_record" {
zone_id = data.aws_route53_zone.external.id
name = var.metabase_domain_name
type = "CNAME"
ttl = "60"
records = [module.metabase_alb.lb_dns_name]
}