From 3b9baf728c861f751540c8b5b69cf0cf395602c7 Mon Sep 17 00:00:00 2001 From: christian-calabrese Date: Fri, 10 Jan 2025 09:59:16 +0100 Subject: [PATCH] [PE-881] Output PEP's recordsets for App Services (#201) --- .changeset/tame-seals-shop.md | 5 +++++ infra/modules/azure_app_service/outputs.tf | 14 ++++++++------ 2 files changed, 13 insertions(+), 6 deletions(-) create mode 100644 .changeset/tame-seals-shop.md diff --git a/.changeset/tame-seals-shop.md b/.changeset/tame-seals-shop.md new file mode 100644 index 000000000..cfeedf5d8 --- /dev/null +++ b/.changeset/tame-seals-shop.md @@ -0,0 +1,5 @@ +--- +"azure_app_service": patch +--- + +Adding to outputs the recordsets pointing to app services' private endpoint diff --git a/infra/modules/azure_app_service/outputs.tf b/infra/modules/azure_app_service/outputs.tf index 7eb743b75..2bb4c91ec 100644 --- a/infra/modules/azure_app_service/outputs.tf +++ b/infra/modules/azure_app_service/outputs.tf @@ -13,13 +13,15 @@ output "app_service" { name = try(azurerm_service_plan.this[0].name, null) } app_service = { - id = azurerm_linux_web_app.this.id - name = azurerm_linux_web_app.this.name - principal_id = azurerm_linux_web_app.this.identity[0].principal_id + id = azurerm_linux_web_app.this.id + name = azurerm_linux_web_app.this.name + principal_id = azurerm_linux_web_app.this.identity[0].principal_id + pep_record_sets = azurerm_private_endpoint.app_service_sites.private_dns_zone_configs[0].record_sets slot = { - id = try(azurerm_linux_web_app_slot.this[0].id, null) - name = try(azurerm_linux_web_app_slot.this[0].name, null) - principal_id = try(azurerm_linux_web_app_slot.this[0].identity[0].principal_id, null) + id = try(azurerm_linux_web_app_slot.this[0].id, null) + name = try(azurerm_linux_web_app_slot.this[0].name, null) + principal_id = try(azurerm_linux_web_app_slot.this[0].identity[0].principal_id, null) + pep_record_sets = try(azurerm_private_endpoint.staging_app_service_sites[0].private_dns_zone_configs[0].record_sets, null) } } }