Skip to content

Instantly share code, notes, and snippets.

@xximjasonxx
Created July 5, 2019 21:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xximjasonxx/d8f9d45b5297fcb6ce48ded8b0851c53 to your computer and use it in GitHub Desktop.
Save xximjasonxx/d8f9d45b5297fcb6ce48ded8b0851c53 to your computer and use it in GitHub Desktop.
Azure Function v2 Resource Block
resource "azurerm_function_app" "main" {
name = "${var.resource-prefix}-analyticsapp"
location = "${azurerm_resource_group.main.location}"
resource_group_name = "${azurerm_resource_group.main.name}"
app_service_plan_id = "${azurerm_app_service_plan.main.id}"
storage_connection_string = "${azurerm_storage_account.main.primary_connection_string}"
version = "~2"
app_settings {
FUNCTIONS_EXTENSION_VERSION = "~2"
FUNCTIONS_WORKER_RUNTIME = "dotnet"
}
site_config {
always_on = true
linux_fx_version = "DOCKER|mcr.microsoft.com/azure-functions/dotnet:2.0-appservice"
use_32_bit_worker_process = true
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment