Skip to content

Commit

Permalink
fix: (IAC-1321) updates to create NSG in network rg (#365)
Browse files Browse the repository at this point in the history
  • Loading branch information
riragh authored Feb 22, 2024
1 parent 29ee26c commit 34773e1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion locals.tf
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ locals {
)

nsg = var.nsg_name == null ? azurerm_network_security_group.nsg[0] : data.azurerm_network_security_group.nsg[0]
nsg_rg_name = var.nsg_name == null ? local.aks_rg.name : local.network_rg.name
nsg_rg_name = local.network_rg.name

# Use BYO UAI if given, else create a UAI
aks_uai_id = (var.aks_identity == "uai"
Expand Down
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ resource "azurerm_network_security_group" "nsg" {
count = var.nsg_name == null ? 1 : 0
name = "${var.prefix}-nsg"
location = var.location
resource_group_name = local.aks_rg.name
resource_group_name = local.network_rg.name
tags = var.tags
}

Expand Down

0 comments on commit 34773e1

Please sign in to comment.