From 9683416d34ac0c73b439a869c3f28af19337b5b2 Mon Sep 17 00:00:00 2001 From: ccuffari <75679158+ccuffari@users.noreply.github.com> Date: Thu, 7 Nov 2024 14:28:23 +0100 Subject: [PATCH] CES-459-migrate-iopstelt new code modified --- src/domains/elt/_modules/storage_accounts/data.tf | 6 +++--- src/domains/elt/_modules/storage_accounts/locals.tf | 10 ++++++---- .../storage_accounts/storage_account_elt.tf | 13 ++++++------- 3 files changed, 15 insertions(+), 14 deletions(-) diff --git a/src/domains/elt/_modules/storage_accounts/data.tf b/src/domains/elt/_modules/storage_accounts/data.tf index e6c484cc0..ddc2051c6 100644 --- a/src/domains/elt/_modules/storage_accounts/data.tf +++ b/src/domains/elt/_modules/storage_accounts/data.tf @@ -1,9 +1,9 @@ data "azurerm_virtual_network" "vnet_itn" { - name = "${var.project}-itn-common-vnet-01" - resource_group_name = "${var.project}-itn-common-rg-01" + name = "${local.prefix}-${local.env_short}-itn-common-vnet-01" + resource_group_name = "${local.prefix}-${local.env_short}-itn-common-rg-01" } -data "azurerm_subnet" "subnet_private_endpoints_itn" { +data "azurerm_subnet" "subnet_pep_itn" { name = "io-p-itn-pep-snet-01 " resource_group_name = data.azurerm_virtual_network.vnet_itn.resource_group_name virtual_network_name = data.azurerm_virtual_network.vnet_itn.name diff --git a/src/domains/elt/_modules/storage_accounts/locals.tf b/src/domains/elt/_modules/storage_accounts/locals.tf index bfd324646..0fea13712 100644 --- a/src/domains/elt/_modules/storage_accounts/locals.tf +++ b/src/domains/elt/_modules/storage_accounts/locals.tf @@ -1,14 +1,16 @@ ###Italy North locals { - prefix = "io" - env_short = "p" - domain = "elt" + prefix = "io" + env_short = "p" + domain = "elt" + app_name = "ex" instance_number = "01" itn_environment = { prefix = local.prefix env_short = local.env_short location = var.location + app_name = local.app_name domain = local.domain instance_number = local.instance_number - } + } } \ No newline at end of file diff --git a/src/domains/elt/_modules/storage_accounts/storage_account_elt.tf b/src/domains/elt/_modules/storage_accounts/storage_account_elt.tf index 0f7e3dbb1..2058b0b84 100644 --- a/src/domains/elt/_modules/storage_accounts/storage_account_elt.tf +++ b/src/domains/elt/_modules/storage_accounts/storage_account_elt.tf @@ -151,18 +151,17 @@ resource "azurerm_storage_table" "fneltexports_itn_02" { module "azure_storage_account" { source = "github.com/pagopa/dx//infra/modules/azure_storage_account?ref=main" - environment = local.itn_environment - resource_group_name = var.resource_group_name_itn - access_tier = "Hot" - + environment = local.itn_environment + resource_group_name = var.resource_group_name_itn + tier = "l" subnet_pep_id = data.azurerm_subnet.subnet_pep_itn.id - private_dns_zone_resource_group_name = "${local.prefix}-${local.env_short}-itn-common-rg-01" + private_dns_zone_resource_group_name = "${local.prefix}-${local.env_short}-rg-common" subservices_enabled = { blob = true file = false - queue = false - table = true + queue = false + table = true } force_public_network_access_enabled = true