Skip to content
This repository has been archived by the owner on Jul 26, 2024. It is now read-only.

Commit

Permalink
Update for #12 - modules update
Browse files Browse the repository at this point in the history
  • Loading branch information
arnaudlh committed Feb 10, 2020
1 parent 5c105c0 commit 6417f3f
Show file tree
Hide file tree
Showing 16 changed files with 74 additions and 62 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ resource_groups_shared_egress = {
# Settings for the shared services egress vnet - note that Azure Firewall subnet must be at least /26
networking_egress = {
vnet = {
name = "-Shared-Egress"
name = "Shared-Egress"
address_space = ["10.0.0.0/25"]
dns = ["192.168.0.16", "192.168.0.64"]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@ locals {

module "networking_shared_egress_vnet" {
source = "aztfmod/caf-virtual-network/azurerm"
version = "0.2.0"

version = "1.0.0"

convention = var.global_settings.convention
virtual_network_rg = local.HUB-EGRESS-NET
prefix = var.prefix
location = var.location
Expand All @@ -28,8 +29,9 @@ module "networking_shared_egress_vnet" {

module "networking_shared_public_ip" {
source = "aztfmod/caf-public-ip/azurerm"
version = "0.1.3"
version = "1.0.0"

convention = var.global_settings.convention
name = var.ip_addr_config.ip_name
location = var.location
rg = local.HUB-EGRESS-NET
Expand All @@ -42,10 +44,11 @@ module "networking_shared_public_ip" {

module "networking_shared_egress_azfirewall" {
source = "aztfmod/caf-azure-firewall/azurerm"
version = "0.1.2"
version = "1.0.0"

az_fw_name = var.az_fw_config.name
az_fw_rg = local.HUB-EGRESS-NET
convention = var.global_settings.convention
name = var.az_fw_config.name
rg = local.HUB-EGRESS-NET
subnet_id = lookup(module.networking_shared_egress_vnet.vnet_subnets, "AzureFirewallSubnet", null)
public_ip_id = module.networking_shared_public_ip.id
location = var.location
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,7 @@ variable "diagnostics_map" {

variable "resource_groups_shared_egress" {
}

variable "global_settings" {
description = "global settings"
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ ddos_name = "ddos_protection_plan"

shared_services_vnet = {
vnet = {
name = "_Shared_Services"
name = "Shared-Services"
address_space = ["10.101.4.0/22"]
dns = []
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ locals {
HUB-CORE-NET = lookup(module.resource_group.names, "HUB-CORE-NET", null)
}


module "networking_shared_services" {
source = "aztfmod/caf-virtual-network/azurerm"
version = "0.2.0"
version = "1.0.0"

convention = var.global_settings.convention
virtual_network_rg = local.HUB-CORE-NET
prefix = var.prefix
location = var.location
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,8 @@ variable "bastion_config" {

variable "enable_bastion" {
description = "Switch to enable Azure Bastion // reserved for future use"
}

variable "global_settings" {
description = "global settings"
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ resource_groups_shared_transit = {
# Settings for the shared services egress vnet
networking_transit = {
vnet = {
name = "_Shared_Transit"
name = "Shared-Transit"
address_space = ["172.16.0.0/23"]
dns = ["192.168.0.16", "192.168.0.64"]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@ locals {

module "networking_transit_vnet" {
source = "aztfmod/caf-virtual-network/azurerm"
version = "0.2.0"
version = "1.0.0"

convention = var.global_settings.convention
virtual_network_rg = local.HUB-NET-TRANSIT
prefix = var.prefix
location = var.location
Expand All @@ -28,8 +29,9 @@ module "networking_transit_vnet" {

module "networking_transit_public_ip" {
source = "aztfmod/caf-public-ip/azurerm"
version = "0.1.3"
version = "1.0.0"

convention = var.global_settings.convention
name = var.ip_addr_config.name
location = var.location
rg = local.HUB-NET-TRANSIT
Expand Down Expand Up @@ -61,8 +63,9 @@ module "vpn_gateway" {

module "keyvault" {
source = "aztfmod/caf-keyvault/azurerm"
version = "0.1.1"
version = "1.0.0"

convention = var.global_settings.convention
rg = local.HUB-NET-TRANSIT
akv_config = var.akv_config
prefix = var.prefix
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,3 +73,7 @@ variable "provision_gateway" {
variable "akv_config" {

}

variable "global_settings" {
description = "global settings"
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# settings for the shared services blueprint

# settings for the operations blueprint
# #Azure Site Recovery Configuration
asr_config = {
asr_vault_name = "asr"
Expand Down
30 changes: 16 additions & 14 deletions landingzones/landingzone_vdc_demo/blueprint_operations/blueprint.tf
Original file line number Diff line number Diff line change
@@ -1,27 +1,29 @@
#Specify the Azure Site Recovery repository
module "site_recovery" {
source = "aztfmod/caf-site-recovery/azurerm"
version = "0.1.2"
version = "1.0.0"

asr_vault_name = var.asr_vault_name
resource_group_name = var.asr_rg
convention = var.global_settings.convention
name = var.asr_config.asr_vault_name
rg = var.asr_rg
location = var.location
tags = var.tags
la_workspace_id = var.log_analytics_workspace.id
diagnostics_map = var.diagnostics_map
diagnostics_settings = var.asr_diags
tags = var.global_settings.tags_hub
la_workspace_id = var.caf_foundations_accounting.log_analytics_workspace.id
diagnostics_map = var.caf_foundations_accounting.diagnostics_map
diagnostics_settings = var.asr_config.asr_diags
}

#Creates the Azure automation account
module "automation" {
source = "aztfmod/caf-automation/azurerm"
version = "0.1.2"
version = "1.0.0"

auto_name = var.auto_account
resource_group_name = var.auto_rg
convention = var.global_settings.convention
name = var.auto_config.auto_account
rg = var.auto_rg
location = var.location
tags = var.tags
la_workspace_id = var.log_analytics_workspace.id
diagnostics_map = var.diagnostics_map
diagnostics_settings = var.auto_diags
tags = var.global_settings.tags_hub
la_workspace_id = var.caf_foundations_accounting.log_analytics_workspace.id
diagnostics_map = var.caf_foundations_accounting.diagnostics_map
diagnostics_settings = var.auto_config.auto_diags
}
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ locals {
blueprint_tag = {
"blueprint" = basename(abspath(path.module))
}
tags = merge(var.tags,local.blueprint_tag)
tags = merge(var.global_settings.tags_hub,local.blueprint_tag)
}
36 changes: 12 additions & 24 deletions landingzones/landingzone_vdc_demo/blueprint_operations/variables.tf
Original file line number Diff line number Diff line change
@@ -1,48 +1,36 @@

variable "asr_vault_name" {
description ="Name for the Azure Site Recovery Vault"
variable "asr_config" {
description = "config for the Azure Site Recovery Vault"
}

variable "asr_rg" {
description ="Name for RG of Azure Site Recovery Vault"
}

variable "auto_account" {
description ="Name for the automation account"
variable "auto_config" {
description = "config for the automation account"
}

variable "auto_rg" {
description ="Name for RG of the automation account"
}

variable "log_analytics_workspace" {
description = "map structure with the list of log analytics data"
}

variable "diagnostics_map" {
description = "Structure that contains the diagnostics data."
}

variable "location" {
description = "Azure region to deploy the resources."
}

variable "tags" {
description = "map of the tags to be applied."
}

variable "asr_diags" {
description = "(Required) Structure for the diagnostics to be deployed for ASR."
}

variable "auto_diags" {
description = "(Required) Structure for the diagnostics to be deployed for automation account."
}

variable "resource_groups_operations" {
description = "(Required) resource group for operations"
}

variable "prefix" {
description = "(Optional) Prefix to uniquely identify the deployment"
}

variable "global_settings" {
description = "global settings"
}

variable "caf_foundations_accounting" {
description = "caf_foundations_accounting settings"
}
3 changes: 3 additions & 0 deletions landingzones/landingzone_vdc_demo/bp_networking.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
module "blueprint_networking_shared_services" {
source = "./blueprint_networking_shared_services"

global_settings = local.global_settings
prefix = local.prefix
location = local.global_settings.location_map["region1"]
log_analytics_workspace = local.caf_foundations_accounting.log_analytics_workspace
Expand All @@ -20,6 +21,7 @@ module "blueprint_networking_shared_services" {
module "blueprint_networking_shared_egress" {
source = "./blueprint_networking_shared_egress"

global_settings = local.global_settings
prefix = local.prefix
location = local.global_settings.location_map["region1"]
log_analytics_workspace = local.caf_foundations_accounting.log_analytics_workspace
Expand All @@ -39,6 +41,7 @@ module "blueprint_networking_shared_egress" {
module "blueprint_networking_shared_transit" {
source = "./blueprint_networking_shared_transit"

global_settings = local.global_settings
prefix = local.prefix
location = local.global_settings.location_map["region1"]
log_analytics_workspace = local.caf_foundations_accounting.log_analytics_workspace
Expand Down
11 changes: 4 additions & 7 deletions landingzones/landingzone_vdc_demo/bp_operations.tf
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,13 @@

prefix = local.prefix
location = local.global_settings.location_map["region1"]
log_analytics_workspace = local.caf_foundations_accounting.log_analytics_workspace
diagnostics_map = local.caf_foundations_accounting.diagnostics_map
tags = local.global_settings.tags_hub
caf_foundations_accounting = local.caf_foundations_accounting
global_settings = local.global_settings

resource_groups_operations = lookup(local.caf_foundations_accounting.resource_group_hub_names, "HUB-OPERATIONS", null)
asr_rg = lookup(local.caf_foundations_accounting.resource_group_hub_names, "HUB-OPERATIONS", null)
auto_rg = lookup(local.caf_foundations_accounting.resource_group_hub_names, "HUB-OPERATIONS", null)

asr_vault_name = var.asr_config.asr_vault_name
asr_diags = var.asr_config.asr_diags
auto_diags = var.auto_config.auto_diags
auto_account = var.auto_config.auto_account
asr_config = var.asr_config
auto_config = var.auto_config
}
4 changes: 4 additions & 0 deletions landingzones/landingzone_vdc_demo/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ This landing zone demo is a simplified hub and spoke architecture for you to use

The choice of multiple blueprints and virtual networks might not fit all customer scenario but should illustrate how to compose an environnement and provide a code base to create your desired topology.

## Prerequisites

This landing zone is a "level 2" type of landing zone, which requires you have a set the foundations. The supported lower level landing zone is "landingzone_caf_foundations" which can be found in the same release and must have been applied successfulling before applying this one.

## Overall architecture

The following diagram shows the environment we are deploying for this POC:
Expand Down

0 comments on commit 6417f3f

Please sign in to comment.