forked from aztfmod/terraform-azurerm-caf
-
Notifications
You must be signed in to change notification settings - Fork 1
/
compute_vmware_clusters.tf
51 lines (39 loc) · 2.23 KB
/
compute_vmware_clusters.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
module "vmware_private_clouds" {
depends_on = [module.dynamic_keyvault_secrets]
source = "./modules/compute/vmware_private_clouds"
for_each = local.compute.vmware_private_clouds
global_settings = local.global_settings
client_config = local.client_config
settings = each.value
keyvaults = local.combined_objects_keyvaults
dynamic_keyvault_secrets = local.security.dynamic_keyvault_secrets #module.dynamic_keyvault_secrets
base_tags = local.global_settings.inherit_tags
resource_group = local.combined_objects_resource_groups[try(each.value.resource_group.lz_key, local.client_config.landingzone_key)][try(each.value.resource_group_key, each.value.resource_group.key)]
resource_group_name = can(each.value.resource_group.name) || can(each.value.resource_group_name) ? try(each.value.resource_group.name, each.value.resource_group_name) : null
location = try(local.global_settings.regions[each.value.region], null)
}
output "vmware_private_clouds" {
value = module.vmware_private_clouds
}
module "vmware_clusters" {
source = "./modules/compute/vmware_clusters"
for_each = local.compute.vmware_clusters
global_settings = local.global_settings
client_config = local.client_config
settings = each.value
vmware_cloud_id = can(each.value.vmware_cloud_id) ? each.value.vmware_cloud_id : local.combined_objects_vmware_private_clouds[try(each.value.lz_key, local.client_config.landingzone_key)][each.value.vmware_private_cloud_key].id
}
output "vmware_clusters" {
value = module.vmware_clusters
}
module "vmware_express_route_authorizations" {
source = "./modules/compute/vmware_express_route_authorizations"
for_each = local.compute.vmware_express_route_authorizations
global_settings = local.global_settings
client_config = local.client_config
settings = each.value
vmware_cloud_id = can(each.value.vmware_cloud_id) ? each.value.vmware_cloud_id : local.combined_objects_vmware_private_clouds[try(each.value.lz_key, local.client_config.landingzone_key)][each.value.vmware_private_cloud_key].id
}
output "vmware_express_route_authorizations" {
value = module.vmware_express_route_authorizations
}