Skip to content

Commit aa2910e

Browse files
Fix: Add outputs to Application Insights module, optional Entra ID group memberships for App Services (#147)
* feat/app-services-entra-id-group-memberships * fix: Add outputs to application insights module
1 parent 44dca8d commit aa2910e

File tree

6 files changed

+34
-2
lines changed

6 files changed

+34
-2
lines changed
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,15 @@
1-
21
output "connection_string" {
32
value = azurerm_application_insights.appins.connection_string
43
}
54

65
output "id" {
76
value = azurerm_application_insights.appins.id
87
}
8+
9+
output "name" {
10+
value = azurerm_application_insights.appins.name
11+
}
12+
13+
output "resource_group_name" {
14+
value = azurerm_application_insights.appins.resource_group_name
15+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
resource "azuread_group_member" "function_app" {
2+
for_each = toset(var.entra_id_group_ids)
3+
4+
group_object_id = each.key
5+
member_object_id = azurerm_linux_function_app.function_app.identity.0.principal_id
6+
}

infrastructure/modules/function-app/variables.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,11 @@ variable "cors_allowed_origins" {
5252
default = [""]
5353
}
5454

55+
variable "entra_id_group_ids" {
56+
type = list(string)
57+
default = []
58+
}
59+
5560
variable "ftp_publish_basic_authentication_enabled" {
5661
type = bool
5762
description = "Enable basic authentication for FTP. Defaults to false."
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
resource "azuread_group_member" "function_app" {
2+
for_each = toset(var.entra_id_group_ids)
3+
4+
group_object_id = each.key
5+
member_object_id = azurerm_linux_web_app.this.identity.0.principal_id
6+
}

infrastructure/modules/linux-web-app/variables.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,11 @@ variable "docker_image_name" {
4747
default = ""
4848
}
4949

50+
variable "entra_id_group_ids" {
51+
type = list(string)
52+
default = []
53+
}
54+
5055
variable "ftp_publish_basic_authentication_enabled" {
5156
type = bool
5257
description = "Enable basic authentication for FTP. Defaults to false."

infrastructure/modules/sql-server/main.tf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,10 @@ resource "azurerm_mssql_server" "azure_sql_server" {
2020
}
2121

2222
lifecycle {
23-
ignore_changes = [tags]
23+
ignore_changes = [
24+
tags,
25+
express_vulnerability_assessment_enabled
26+
]
2427
}
2528
}
2629

0 commit comments

Comments
 (0)