-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.tf
82 lines (75 loc) · 3.78 KB
/
main.tf
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
locals {
api_hostname = var.api_hostname != "" ? var.api_hostname : "api.${var.hostname}"
proxy_hostname = var.proxy_hostname != "" ? var.proxy_hostname : "proxy.${var.hostname}"
api_shield_region = var.api_shield_region != "" ? var.api_shield_region : var.shield_region
proxy_shield_region = var.proxy_shield_region != "" ? var.proxy_shield_region : var.shield_region
}
module "app" {
source = "./modules/app"
name = var.name
hostname = var.hostname
default_ttl = var.default_ttl
backend_name = var.backend_name
ssl_hostname = var.ssl_hostname
backend_address = var.backend_address
backend_port = var.backend_port
shield_region = var.shield_region
healthcheck_host = var.healthcheck_host
healthcheck_name = var.healthcheck_name
healthcheck_path = var.healthcheck_path
healthcheck_method = var.healthcheck_method
healthcheck_expected_response = var.healthcheck_expected_response
force_tls_hsts = var.force_tls_hsts
hsts_duration = var.hsts_duration
gzip_default_policy = var.gzip_default_policy
product_enablement = var.product_enablement
datadog = var.datadog
datadog_region = var.datadog_region
datadog_service = var.datadog_service
datadog_token = var.datadog_token
}
module "api" {
source = "./modules/api"
name = var.api_name
hostname = local.api_hostname
default_ttl = var.api_default_ttl
backend_name = var.api_backend_name
ssl_hostname = var.api_ssl_hostname
backend_address = var.api_backend_address
backend_port = var.api_backend_port
backend_ca_cert = var.api_backend_ca_cert
shield_region = local.api_shield_region
healthcheck_host = var.api_healthcheck_host
healthcheck_name = var.api_healthcheck_name
healthcheck_path = var.api_healthcheck_path
healthcheck_method = var.api_healthcheck_method
healthcheck_expected_response = var.api_healthcheck_expected_response
force_tls_hsts = var.api_force_tls_hsts
hsts_duration = var.api_hsts_duration
datadog = var.api_datadog
datadog_region = var.datadog_region
datadog_service = var.api_datadog_service
datadog_token = var.datadog_token
}
module "proxy" {
source = "./modules/proxy"
name = var.proxy_name
hostname = local.proxy_hostname
default_ttl = var.proxy_default_ttl
backend_name = var.proxy_backend_name
ssl_hostname = var.proxy_ssl_hostname
backend_address = var.proxy_backend_address
backend_port = var.backend_port
shield_region = local.proxy_shield_region
healthcheck_host = var.proxy_healthcheck_host
healthcheck_name = var.proxy_healthcheck_name
healthcheck_path = var.proxy_healthcheck_path
healthcheck_method = var.proxy_healthcheck_method
healthcheck_expected_response = var.proxy_healthcheck_expected_response
force_tls_hsts = var.proxy_force_tls_hsts
hsts_duration = var.proxy_hsts_duration
datadog = var.proxy_datadog
datadog_region = var.datadog_region
datadog_service = var.proxy_datadog_service
datadog_token = var.datadog_token
}