Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat-standardise-naming #190

Merged
merged 6 commits into from
Dec 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/end-to-end-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ jobs:

- name: Run Plan
run: |
set +e
terraform -chdir="${{ matrix.rootModuleFolderPath }}" init
terraform -chdir="${{ matrix.rootModuleFolderPath }}" plan -var-file="${{ matrix.configFilePath }}" -out=tfplan
env:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,38 @@ custom_replacements = {
dcr_defender_sql_name = "dcr-defender-sql"
dcr_vm_insights_name = "dcr-vm-insights"

# Resource names primary connectivity
primary_virtual_network_name = "vnet-hub-$${starter_location_01}"
primary_subnet_nva_name = "subnet-nva-$${starter_location_01}"
primary_route_table_firewall_name = "rt-hub-fw-$${starter_location_01}"
primary_route_table_user_subnets_name = "rt-hub-std-$${starter_location_01}"
primary_virtual_network_gateway_express_route_name = "vgw-hub-er-$${starter_location_01}"
primary_virtual_network_gateway_express_route_public_ip_name = "pip-vgw-hub-er-$${starter_location_01}"
primary_virtual_network_gateway_vpn_name = "vgw-hub-vpn-$${starter_location_01}"
primary_virtual_network_gateway_vpn_public_ip_name = "pip-vgw-hub-vpn-$${starter_location_01}"
primary_private_dns_resolver_name = "pdr-hub-dns-$${starter_location_01}"
primary_bastion_host_name = "btn-hub-$${starter_location_01}"
primary_bastion_host_public_ip_name = "pip-bastion-hub-$${starter_location_01}"

# Resource names secondary connectivity
secondary_virtual_network_name = "vnet-hub-$${starter_location_02}"
secondary_subnet_nva_name = "subnet-nva-$${starter_location_02}"
secondary_route_table_firewall_name = "rt-hub-fw-$${starter_location_02}"
secondary_route_table_user_subnets_name = "rt-hub-std-$${starter_location_02}"
secondary_virtual_network_gateway_express_route_name = "vgw-hub-er-$${starter_location_02}"
secondary_virtual_network_gateway_express_route_public_ip_name = "pip-vgw-hub-er-$${starter_location_02}"
secondary_virtual_network_gateway_vpn_name = "vgw-hub-vpn-$${starter_location_02}"
secondary_virtual_network_gateway_vpn_public_ip_name = "pip-vgw-hub-vpn-$${starter_location_02}"
secondary_private_dns_resolver_name = "pdr-hub-dns-$${starter_location_02}"
secondary_bastion_host_name = "btn-hub-$${starter_location_02}"
secondary_bastion_host_public_ip_name = "pip-bastion-hub-$${starter_location_02}"

# Private DNS Zones primary
primary_auto_registration_zone_name = "$${starter_location_01}.azure.local"

# Private DNS Zones secondary
secondary_auto_registration_zone_name = "$${starter_location_02}.azure.local"

# IP Ranges Primary
# Regional Address Space: 10.0.0.0/16
primary_hub_address_space = "10.0.0.0/16"
Expand Down Expand Up @@ -103,7 +135,7 @@ tags = {

/*
--- Management Resources ---
You can use this section to customise the management resources that will be deployed.
You can use this section to customize the management resources that will be deployed.
*/
management_resource_settings = {
automation_account_name = "$${automation_account_name}"
Expand All @@ -130,7 +162,7 @@ management_resource_settings = {

/*
--- Management Groups and Policy ---
You can use this section to customise the management groups and policies that will be deployed.
You can use this section to customize the management groups and policies that will be deployed.
You can further configure management groups and policy by supplying a `lib` folder. This is detailed in the Accelerator documentation.
*/
management_group_settings = {
Expand Down Expand Up @@ -213,7 +245,7 @@ management_group_settings = {

/*
--- Connectivity - Hub and Spoke Virtual Network ---
You can use this section to customise the hub virtual networking that will be deployed.
You can use this section to customize the hub virtual networking that will be deployed.
*/
connectivity_type = "hub_and_spoke_vnet"

Expand Down Expand Up @@ -247,20 +279,20 @@ hub_and_spoke_vnet_settings = {
hub_and_spoke_vnet_virtual_networks = {
primary = {
hub_virtual_network = {
name = "vnet-hub-$${starter_location_01}"
name = "$${primary_virtual_network_name}"
resource_group_name = "$${connectivity_hub_primary_resource_group_name}"
resource_group_creation_enabled = false
location = "$${starter_location_01}"
address_space = ["$${primary_hub_virtual_network_address_space}"]
routing_address_space = ["$${primary_hub_address_space}"]
route_table_name_firewall = "rt-hub-fw-$${starter_location_01}"
route_table_name_user_subnets = "rt-hub-std-$${starter_location_01}"
route_table_name_firewall = "$${primary_route_table_firewall_name}"
route_table_name_user_subnets = "$${primary_route_table_user_subnets_name}"
mesh_peering = true
ddos_protection_plan_id = "$${management_resource_group_id}/providers/Microsoft.Network/ddosProtectionPlans/$${ddos_protection_plan_name}"
ddos_protection_plan_id = "$${ddos_protection_plan_id}"
hub_router_ip_address = "$${primary_nva_ip_address}"
subnets = {
nva = {
name = "subnet-nva-$${starter_location_01}"
name = "$${primary_subnet_nva_name}"
address_prefixes = ["$${primary_nva_subnet_address_prefix}"]
}
}
Expand All @@ -269,27 +301,25 @@ hub_and_spoke_vnet_virtual_networks = {
subnet_address_prefix = "$${primary_gateway_subnet_address_prefix}"
express_route = {
location = "$${starter_location_01}"
name = "vgw-hub-expressroute-$${starter_location_01}"
name = "$${primary_virtual_network_gateway_express_route_name}"
sku = "$${starter_location_01_virtual_network_gateway_sku_express_route}"
ip_configurations = {
default = {
name = "ipconfig-vgw-hub-expressroute-$${starter_location_01}"
public_ip = {
name = "pip-vgw-hub-expressroute-$${starter_location_01}"
name = "$${primary_virtual_network_gateway_express_route_public_ip_name}"
zones = "$${starter_location_01_availability_zones}"
}
}
}
}
vpn = {
location = "$${starter_location_01}"
name = "vgw-hub-vpn-$${starter_location_01}"
name = "$${primary_virtual_network_gateway_vpn_name}"
sku = "$${starter_location_01_virtual_network_gateway_sku_vpn}"
ip_configurations = {
default = {
name = "ipconfig-vgw-hub-vpn-$${starter_location_01}"
public_ip = {
name = "pip-vgw-hub-vpn-$${starter_location_01}"
name = "$${primary_virtual_network_gateway_vpn_public_ip_name}"
zones = "$${starter_location_01_availability_zones}"
}
}
Expand All @@ -300,39 +330,39 @@ hub_and_spoke_vnet_virtual_networks = {
resource_group_name = "$${dns_resource_group_name}"
is_primary = true
auto_registration_zone_enabled = true
auto_registration_zone_name = "$${starter_location_01}.azure.local"
auto_registration_zone_name = "$${primary_auto_registration_zone_name}.azure.local"
subnet_address_prefix = "$${primary_private_dns_resolver_subnet_address_prefix}"
private_dns_resolver = {
name = "pdr-hub-dns-$${starter_location_01}"
name = "$${primary_private_dns_resolver_name}"
}
}
bastion = {
subnet_address_prefix = "$${primary_bastion_subnet_address_prefix}"
bastion_host = {
name = "bastion-hub-$${starter_location_01}"
name = "$${primary_bastion_host_name}"
}
bastion_public_ip = {
name = "pip-bastion-hub-$${starter_location_01}"
name = "$${primary_bastion_host_public_ip_name}"
zones = "$${starter_location_01_availability_zones}"
}
}
}
secondary = {
hub_virtual_network = {
name = "vnet-hub-$${starter_location_02}"
name = "$${secondary_virtual_network_name}"
resource_group_name = "$${connectivity_hub_secondary_resource_group_name}"
resource_group_creation_enabled = false
location = "$${starter_location_02}"
address_space = ["$${secondary_hub_virtual_network_address_space}"]
routing_address_space = ["$${secondary_hub_address_space}"]
route_table_name_firewall = "rt-hub-fw-$${starter_location_02}"
route_table_name_user_subnets = "rt-hub-std-$${starter_location_02}"
route_table_name_firewall = "$${secondary_route_table_firewall_name}"
route_table_name_user_subnets = "$${secondary_route_table_user_subnets_name}"
mesh_peering = true
ddos_protection_plan_id = "$${management_resource_group_id}/providers/Microsoft.Network/ddosProtectionPlans/$${ddos_protection_plan_name}"
ddos_protection_plan_id = "$${ddos_protection_plan_id}"
hub_router_ip_address = "$${secondary_nva_ip_address}"
subnets = {
nva = {
name = "subnet-nva-$${starter_location_02}"
name = "$${secondary_subnet_nva_name}"
address_prefixes = ["$${secondary_nva_subnet_address_prefix}"]
}
}
Expand All @@ -341,27 +371,25 @@ hub_and_spoke_vnet_virtual_networks = {
subnet_address_prefix = "$${secondary_gateway_subnet_address_prefix}"
express_route = {
location = "$${starter_location_02}"
name = "vgw-hub-expressroute-$${starter_location_02}"
name = "$${secondary_virtual_network_gateway_express_route_name}"
sku = "$${starter_location_02_virtual_network_gateway_sku_express_route}"
ip_configurations = {
default = {
name = "ipconfig-vgw-hub-expressroute-$${starter_location_02}"
public_ip = {
name = "pip-vgw-hub-expressroute-$${starter_location_02}"
name = "$${secondary_virtual_network_gateway_express_route_public_ip_name}"
zones = "$${starter_location_02_availability_zones}"
}
}
}
}
vpn = {
location = "$${starter_location_02}"
name = "vgw-hub-vpn-$${starter_location_02}"
name = "$${secondary_virtual_network_gateway_vpn_name}"
sku = "$${starter_location_02_virtual_network_gateway_sku_vpn}"
ip_configurations = {
default = {
name = "ipconfig-vgw-hub-vpn-$${starter_location_02}"
public_ip = {
name = "pip-vgw-hub-vpn-$${starter_location_02}"
name = "$${secondary_virtual_network_gateway_vpn_public_ip_name}"
zones = "$${starter_location_02_availability_zones}"
}
}
Expand All @@ -372,19 +400,19 @@ hub_and_spoke_vnet_virtual_networks = {
resource_group_name = "$${dns_resource_group_name}"
is_primary = false
auto_registration_zone_enabled = true
auto_registration_zone_name = "$${starter_location_02}.azure.local"
auto_registration_zone_name = "$${secondary_auto_registration_zone_name}.azure.local"
subnet_address_prefix = "$${secondary_private_dns_resolver_subnet_address_prefix}"
private_dns_resolver = {
name = "pdr-hub-dns-$${starter_location_02}"
name = "$${secondary_private_dns_resolver_name}"
}
}
bastion = {
subnet_address_prefix = "$${secondary_bastion_subnet_address_prefix}"
bastion_host = {
name = "bastion-hub-$${starter_location_02}"
name = "$${secondary_bastion_host_name}"
}
bastion_public_ip = {
name = "pip-bastion-hub-$${starter_location_02}"
name = "$${secondary_bastion_host_public_ip_name}"
zones = "$${starter_location_02_availability_zones}"
}
}
Expand Down
Loading
Loading