Skip to content

Commit 25a0256

Browse files
authored
envs with app insights
1 parent 66c4b47 commit 25a0256

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

terraform-infrastructure/main.tf

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,17 @@ resource "azurerm_linux_function_app" "function_app" {
8989
}
9090
}
9191

92-
depends_on = [azurerm_service_plan.asp]
92+
app_settings = {
93+
"FUNCTIONS_WORKER_RUNTIME" = "python"
94+
"WEBSITE_RUN_FROM_PACKAGE" = "1"
95+
"APPINSIGHTS_INSTRUMENTATIONKEY" = azurerm_application_insights.appinsights.instrumentation_key
96+
"APPLICATIONINSIGHTS_CONNECTION_STRING" = azurerm_application_insights.appinsights.connection_string
97+
}
98+
99+
depends_on = [
100+
azurerm_service_plan.asp,
101+
azurerm_application_insights.appinsights
102+
]
93103

94104
provisioner "local-exec" {
95105
command = "echo Function App: ${self.name}"

0 commit comments

Comments
 (0)