-
Notifications
You must be signed in to change notification settings - Fork 0
/
outputs.tf
78 lines (63 loc) · 2.29 KB
/
outputs.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
output "dns_entries" {
value = templatefile("${path.module}/templates/dns.zone", {
"node_name_suffix" = local.node_name_suffix,
"api_vip" = var.enable_api_vip && var.lb_count != 0 ? split("/", module.lb.api_vip[0].network)[0] : ""
"router_vip" = var.enable_router_vip && var.lb_count != 0 ? split("/", module.lb.router_vip[0].network)[0] : ""
"egress_vip" = var.enable_nat_vip && var.lb_count != 0 ? split("/", module.lb.nat_vip[0].network)[0] : ""
"internal_vip" = local.internal_vip,
"internal_router_vip" = var.internal_router_vip,
"masters" = module.master.ip_addresses,
"cluster_id" = var.cluster_id,
"lbs" = module.lb.public_ipv4_addresses,
"lb_hostnames" = module.lb.server_names
})
}
output "node_name_suffix" {
value = local.node_name_suffix
}
output "subnet_uuid" {
value = local.subnet_uuid
}
output "region" {
value = var.region
}
output "cluster_id" {
value = var.cluster_id
}
output "ignition_ca" {
value = var.ignition_ca
}
output "api_int" {
value = "api-int.${local.node_name_suffix}"
}
output "hieradata_mr" {
value = module.lb.hieradata_mr_url
}
output "master-machines_yml" {
value = var.make_master_adoptable_by_provider ? module.master.machine_yml : null
}
output "master-machineset_yml" {
value = var.make_master_adoptable_by_provider ? module.master.machineset_yml : null
}
output "infra-machines_yml" {
value = var.make_worker_adoptable_by_provider ? module.infra.machine_yml : null
}
output "infra-machineset_yml" {
value = var.make_worker_adoptable_by_provider ? module.infra.machineset_yml : null
}
output "worker-machines_yml" {
value = var.make_worker_adoptable_by_provider ? module.worker.machine_yml : null
}
output "worker-machineset_yml" {
value = var.make_worker_adoptable_by_provider ? module.worker.machineset_yml : null
}
output "additional-worker-machines_yml" {
value = var.make_worker_adoptable_by_provider ? yamlencode({
"apiVersion" = "v1",
"kind" = "List",
"items" = flatten(values(module.additional_worker)[*].machines)
}) : null
}
output "additional-worker-machinesets_yml" {
value = var.make_worker_adoptable_by_provider ? join("\n---\n", values(module.additional_worker)[*].machineset_yml) : null
}