Microsoft.Web serverfarms

Bicep resource definition

The serverfarms resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Web/serverfarms resource, add the following Bicep to your template.

resource symbolicname 'Microsoft.Web/serverfarms@2022-09-01' = {
  name: 'string'
  location: 'string'
  tags: {
    tagName1: 'tagValue1'
    tagName2: 'tagValue2'
  }
  sku: {
    capabilities: [
      {
        name: 'string'
        reason: 'string'
        value: 'string'
      }
    ]
    capacity: int
    family: 'string'
    locations: [
      'string'
    ]
    name: 'string'
    size: 'string'
    skuCapacity: {
      default: int
      elasticMaximum: int
      maximum: int
      minimum: int
      scaleType: 'string'
    }
    tier: 'string'
  }
  kind: 'string'
  extendedLocation: {
    name: 'string'
  }
  properties: {
    elasticScaleEnabled: bool
    freeOfferExpirationTime: 'string'
    hostingEnvironmentProfile: {
      id: 'string'
    }
    hyperV: bool
    isSpot: bool
    isXenon: bool
    kubeEnvironmentProfile: {
      id: 'string'
    }
    maximumElasticWorkerCount: int
    perSiteScaling: bool
    reserved: bool
    spotExpirationTime: 'string'
    targetWorkerCount: int
    targetWorkerSizeId: int
    workerTierName: 'string'
    zoneRedundant: bool
  }
}

Property values

serverfarms

Name Description Value
name The resource name string (required)

Character limit: 1-60

Valid characters:
Alphanumeric, hyphens and Unicode characters that can be mapped to Punycode
location Resource Location. string (required)
tags Resource tags. Dictionary of tag names and values. See Tags in templates
sku Description of a SKU for a scalable resource. SkuDescription
kind Kind of resource. string
extendedLocation Extended Location. ExtendedLocation
properties AppServicePlan resource specific properties AppServicePlanProperties

ExtendedLocation

Name Description Value
name Name of extended location. string

AppServicePlanProperties

Name Description Value
elasticScaleEnabled ServerFarm supports ElasticScale. Apps in this plan will scale as if the ServerFarm was ElasticPremium sku bool
freeOfferExpirationTime The time when the server farm free offer expires. string
hostingEnvironmentProfile Specification for the App Service Environment to use for the App Service plan. HostingEnvironmentProfile
hyperV If Hyper-V container app service plan true, false otherwise. bool
isSpot If true, this App Service Plan owns spot instances. bool
isXenon Obsolete: If Hyper-V container app service plan true, false otherwise. bool
kubeEnvironmentProfile Specification for the Kubernetes Environment to use for the App Service plan. KubeEnvironmentProfile
maximumElasticWorkerCount Maximum number of total workers allowed for this ElasticScaleEnabled App Service Plan int
perSiteScaling If true, apps assigned to this App Service plan can be scaled independently.
If false, apps assigned to this App Service plan will scale to all instances of the plan.
bool
reserved If Linux app service plan true, false otherwise. bool
spotExpirationTime The time when the server farm expires. Valid only if it is a spot server farm. string
targetWorkerCount Scaling worker count. int
targetWorkerSizeId Scaling worker size ID. int
workerTierName Target worker tier assigned to the App Service plan. string
zoneRedundant If true, this App Service Plan will perform availability zone balancing.
If false, this App Service Plan will not perform availability zone balancing.
bool

HostingEnvironmentProfile

Name Description Value
id Resource ID of the App Service Environment. string

KubeEnvironmentProfile

Name Description Value
id Resource ID of the Kubernetes Environment. string

SkuDescription

Name Description Value
capabilities Capabilities of the SKU, e.g., is traffic manager enabled? Capability[]
capacity Current number of instances assigned to the resource. int
family Family code of the resource SKU. string
locations Locations of the SKU. string[]
name Name of the resource SKU. string
size Size specifier of the resource SKU. string
skuCapacity Min, max, and default scale values of the SKU. SkuCapacity
tier Service tier of the resource SKU. string

Capability

Name Description Value
name Name of the SKU capability. string
reason Reason of the SKU capability. string
value Value of the SKU capability. string

SkuCapacity

Name Description Value
default Default number of workers for this App Service plan SKU. int
elasticMaximum Maximum number of Elastic workers for this App Service plan SKU. int
maximum Maximum number of workers for this App Service plan SKU. int
minimum Minimum number of workers for this App Service plan SKU. int
scaleType Available scale configurations for an App Service plan. string

Quickstart templates

The following quickstart templates deploy this resource type.

Template Description
Function App

Deploy to Azure
This template deploy an empty Function App and a hosting plan.
App Service Quickstart - Linux App

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
App Service Quickstart - Windows app

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
App Service Quickstart - Windows container app

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
Deploy an app service with regional VNet integration

Deploy to Azure
This template allows you to deploy an app service plan and a basic Windows web app, with regional VNet integration enabled to a newly created virtual network
App Service Environment with Azure SQL backend

Deploy to Azure
This template creates an App Service Environment with an Azure SQL backend along with private endpoints along with associated resources typically used in an private/isolated environment.
App Service Environment with Hosting Plan and Azure WebApp

Deploy to Azure
Creates an App Service Environment v2 with an ILB Address in a existing virtual network that will be privately availible. The App Service Environment will contain a Hosting Plan and a Azure Web App
Create Azure App Service Environment With An Web App Added

Deploy to Azure
Creates an Azure App Service Environment inside A Virtual Network Subnet. This template also adds a Azure Web App inside the App Service Environment. Template originally authored by Callum Brankin of PixelPin
Azure Cosmos DB Account with Web App

Deploy to Azure
This template deploys an Azure Cosmos DB account, an App Service Plan, and creates a Web App in the App Service Plan. It also adds two Application settings to the Web App that reference the Azure Cosmos DB account endpoint. This way solutions deployed to the Web App can connect to the Azure Cosmos DB account endpoint using those settings.
Provision a function app running on an App Service Plan

Deploy to Azure
This template provisions a function app on a dedicated hosting plan, meaning it will be run and billed just like any App Service site.
Provision a function app on a Consumption plan

Deploy to Azure
This template provisions a function app on a Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment. There are other templates available for provisioning on a dedicated hosting plan.
Provision Consumption plan function with a Deployment Slot

Deploy to Azure
This template provisions a function app on a Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment. There are other templates available for provisioning on a dedicated hosting plan.
Provision a function app with source deployed from GitHub

Deploy to Azure
This template deploys a Function App hosted in a new dedicated App Service Plan. The Function App has a child resource that enables continous integration and deploys the function code from a GitHub repository.
Azure Function App Hosted on Dedicated Plan

Deploy to Azure
This template provisions a function app on a dedicated hosting plan, meaning it will be run and billed just like any App Service site.
Azure Function App with a Deployment Slot

Deploy to Azure
This template provisions a function app on a Premium plan with production slot and an additional deployment slot.
Azure Function App with Event Hub and Managed Identity

Deploy to Azure
his template provisions an Azure Function app on a Linux Consumption plan, along with an Event Hub, Azure Storage, and Application Insights. The function app is able to use managed identity to connect to the Event Hub and Storage account
Azure Function App Hosted on Linux Consumption Plan

Deploy to Azure
This template provisions a function app on a Linux Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment.
Function App on Linux Consumption Plan with Remote Build

Deploy to Azure
This template provisions a function app on a Linux Consumption plan and perform remote build during code deployment. The app runs on demand and you're billed per execution, with no standing resource committment.
Azure Function App Hosted on Premium Plan

Deploy to Azure
This template provisions a function app on a Premium plan.
Private Function App and private endpoint-secured Storage

Deploy to Azure
This template provisions a function app on a Premium plan that has private endpoints and communicates with Azure Storage over private endpoints.
Create Function App and private endpoint-secured Storage

Deploy to Azure
This template allows you to deploy an Azure Function App that communicates with Azure Storage over private endpoints.
Azure Function App with Virtual Network Integration

Deploy to Azure
This template provisions a function app on a Premium plan with regional virtual network integration enabled to a newly created virtual network.
Azure Function App Hosted on Windows Consumption Plan

Deploy to Azure
This template provisions a function app on a Windows Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment.
Azure Function app and an HTTP-triggered function

Deploy to Azure
This example deploys an Azure Function app and an HTTP-triggered function inline in the template. It also deploys a Key Vault and populates a secret with the function app's host key.
Deploy an AZ enabled Azure Function Premium plan

Deploy to Azure
This template allows you to deploy an Azure Function Premium plan with availability zones support, including an availability zones enabled storage account.
Function App secured by Azure Frontdoor

Deploy to Azure
This template allows you to deploy an azure premium function protected and published by Azure Frontdoor premium. The conenction between Azure Frontdoor and Azure Functions is protected by Azure Private Link.
Deploy an Azure Function Premium plan with vnet integration

Deploy to Azure
This template allows you to deploy an Azure Function Premium plan with regional virtual network integration enabled to a newly created virtual network.
Creates a function app with managed service identity

Deploy to Azure
Creates a function app with managed service identity enabled with Application Insights set up for logs and metrics.
Provision a Mobile App with a SQL Database

Deploy to Azure
This template provisions a Mobile App, SQL Database, and Notification Hub. It configures a connection string in the mobile app for the database and notification hub.
Web App with Private Endpoint

Deploy to Azure
This template allows you to create a Web App and expose it through Private Endpoint
Application Gateway with internal API Management and Web App

Deploy to Azure
Application Gateway routing Internet traffic to a virtual network (internal mode) API Management instance which services a web API hosted in an Azure Web App.
Create an AppServicePlan and App in an ASE

Deploy to Azure
Create an AppServicePlan and App in an ASE
Create an AppServicePlan and App in an App. Service Env. v2

Deploy to Azure
Create an AppServicePlan and App in an App Service Environment v2
Create Azure Web app with Blob Storage connection string

Deploy to Azure
Creates an Azure Web app with Blob Storage connection string, Template originally authored by Jeff Bowles of Microsoft
Web App with a custom domain and optional SSL binding

Deploy to Azure
Create a web app and with a custom domain and optionally add SSL certificate for https encryption.
Web App with diagnostics logging to Blob Container

Deploy to Azure
Deploy a Web App with diagnostics logging to Storage Account Blob Container enabled.
Web App Deployment from GitHub

Deploy to Azure
This template allows you to create an WebApp linked with a GitHub Repository linked.
Create a web app on Azure with Java 13 and Tomcat 9 enabled

Deploy to Azure
This template creates a web app on azure with Java 13 and Tomcat 9 enabled allowing you to run Java applications in Azure. Template was authored by Donovan Brown of Microsoft.
Web App w/ Application Insights sending to Log Analytics

Deploy to Azure
This template will is to help support the new API versions of microsoft.insights/components. Starting with 2020-02-02-preview WorkspaceID will be required when creating Application Inisghts.This template will deploy the App Service Plan, App Service, Application Insights, Log Analytics Workspace and hook it all together.
Web App with Managed Identity, SQL Server and ΑΙ

Deploy to Azure
Simple example to deploy Azure infrastructure for app + data + managed identity + monitoring
Create a web app on Azure with Python enabled

Deploy to Azure
This template creates a web app on azure with Python enabled allowing you to run Python applications in Azure. Template was authored by Donovan Brown of Microsoft.
Create a Web App + Redis Cache + SQL DB with a template

Deploy to Azure
This template creates an Azure Web App with Redis cache and a SQL Database.
Provision a Web App with a SQL Database

Deploy to Azure
This template provisions a Web App, a SQL Database, AutoScale settings, Alert rules, and App Insights. It configures a connection string in the web app for the database.
Create a Web App protected by Application Gateway v2

Deploy to Azure
This template creates an Azure Web App with Access Restriction for an Application Gateway v2. The Application Gateway is deployed in a vNet (subnet) which has a 'Microsoft.Web' Service Endpoint enabled. The Web App restricts access to traffic from the subnet.
Create a Web App plus Redis Cache using a template

Deploy to Azure
This template creates an Azure Web App with Redis cache.
Deploy a basic Linux web app

Deploy to Azure
This template allows you to deploy an app service plan and a basic Linux web app
App Service Quickstart - Windows app

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
Web App with custom Deployment slots

Deploy to Azure
This template provides an easy way to deploy a web app with custom deployment slots on Azure Web Apps.
Airflow Docker Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy a puckel/docker-airflow image (latest tag) on a Linux Web App with Azure database for PostgreSQL
Django app

Deploy to Azure
This template allows you to create an App Service for deploying a Django app.
Flask app service

Deploy to Azure
This template allows you to create an App Service for deploying a Flask app.
Build a Web App on Linux with Azure database for MySQL

Deploy to Azure
This template provides a way to deploy Web Apps on Linux with Azure database for MySQL.
Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy Web App on Linux with Azure database for PostgreSQL(Preview).
Node App Service

Deploy to Azure
This template allows you to create an App Service for deploying a Node app.
Sonarqube Docker Web App on Linux with Azure SQL

Deploy to Azure
This template deploys Sonarqube in an Azure App Service web app Linux container using the official Sonarqube image and backed by an Azure SQL Server.
Sonarqube Docker Web App on Linux with MySQL

Deploy to Azure
This template provides a easy way to deploy a Sonarqube docker image (alpine tag) on a Linux Web App with Azure database for MySQL
Sonarqube Docker Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy a Sonarqube docker image (alpine tag) on a Linux Web App with Azure database for PostgreSQL(Preview)
SonarQube on Web App with PostgreSQL and VNet integration

Deploy to Azure
This template provides easy to deploy SonarQube to Web App on Linux with PostgreSQL Flexible Server, VNet integration and private DNS.
Web App with Azure database for MySQL

Deploy to Azure
This template provides a easy way to deploy web app on Azure App Service Web Apps with Azure database for MySQL.
Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy Web App on Linux with Azure database for PostgreSQL.
Highly Available Multi-region Web App

Deploy to Azure
This template allows you to create a secure, highly available, multi-region end to end solution with two web apps in different regions behind Azure Front Door
Web App with VNet Injection and Private Endpoint

Deploy to Azure
This template allows you to create a secure end to end solution with two web apps, front end and back end, front end will consume securely the back through VNet injection and Private Endpoint
Secure N-tier Web App

Deploy to Azure
This template allows you to create a secure end to end solution with two web apps with staging slots, front end and back end, front end will consume securely the back through VNet injection and Private Endpoint
ASP.NET app

Deploy to Azure
This template allows you to create an App Service for deploying a ASP.NET app.
Create a Web App, PE and Application Gateway v2

Deploy to Azure
This template creates an Azure Web App with Private endpoint in Azure Virtual Network Subnet , an Application Gateway v2. The Application Gateway is deployed in a vNet (subnet). The Web App restricts access to traffic from the subnet using private endpoint

ARM template resource definition

The serverfarms resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Web/serverfarms resource, add the following JSON to your template.

{
  "type": "Microsoft.Web/serverfarms",
  "apiVersion": "2022-09-01",
  "name": "string",
  "location": "string",
  "tags": {
    "tagName1": "tagValue1",
    "tagName2": "tagValue2"
  },
  "sku": {
    "capabilities": [
      {
        "name": "string",
        "reason": "string",
        "value": "string"
      }
    ],
    "capacity": "int",
    "family": "string",
    "locations": [ "string" ],
    "name": "string",
    "size": "string",
    "skuCapacity": {
      "default": "int",
      "elasticMaximum": "int",
      "maximum": "int",
      "minimum": "int",
      "scaleType": "string"
    },
    "tier": "string"
  },
  "kind": "string",
  "extendedLocation": {
    "name": "string"
  },
  "properties": {
    "elasticScaleEnabled": "bool",
    "freeOfferExpirationTime": "string",
    "hostingEnvironmentProfile": {
      "id": "string"
    },
    "hyperV": "bool",
    "isSpot": "bool",
    "isXenon": "bool",
    "kubeEnvironmentProfile": {
      "id": "string"
    },
    "maximumElasticWorkerCount": "int",
    "perSiteScaling": "bool",
    "reserved": "bool",
    "spotExpirationTime": "string",
    "targetWorkerCount": "int",
    "targetWorkerSizeId": "int",
    "workerTierName": "string",
    "zoneRedundant": "bool"
  }
}

Property values

serverfarms

Name Description Value
type The resource type 'Microsoft.Web/serverfarms'
apiVersion The resource api version '2022-09-01'
name The resource name string (required)

Character limit: 1-60

Valid characters:
Alphanumeric, hyphens and Unicode characters that can be mapped to Punycode
location Resource Location. string (required)
tags Resource tags. Dictionary of tag names and values. See Tags in templates
sku Description of a SKU for a scalable resource. SkuDescription
kind Kind of resource. string
extendedLocation Extended Location. ExtendedLocation
properties AppServicePlan resource specific properties AppServicePlanProperties

ExtendedLocation

Name Description Value
name Name of extended location. string

AppServicePlanProperties

Name Description Value
elasticScaleEnabled ServerFarm supports ElasticScale. Apps in this plan will scale as if the ServerFarm was ElasticPremium sku bool
freeOfferExpirationTime The time when the server farm free offer expires. string
hostingEnvironmentProfile Specification for the App Service Environment to use for the App Service plan. HostingEnvironmentProfile
hyperV If Hyper-V container app service plan true, false otherwise. bool
isSpot If true, this App Service Plan owns spot instances. bool
isXenon Obsolete: If Hyper-V container app service plan true, false otherwise. bool
kubeEnvironmentProfile Specification for the Kubernetes Environment to use for the App Service plan. KubeEnvironmentProfile
maximumElasticWorkerCount Maximum number of total workers allowed for this ElasticScaleEnabled App Service Plan int
perSiteScaling If true, apps assigned to this App Service plan can be scaled independently.
If false, apps assigned to this App Service plan will scale to all instances of the plan.
bool
reserved If Linux app service plan true, false otherwise. bool
spotExpirationTime The time when the server farm expires. Valid only if it is a spot server farm. string
targetWorkerCount Scaling worker count. int
targetWorkerSizeId Scaling worker size ID. int
workerTierName Target worker tier assigned to the App Service plan. string
zoneRedundant If true, this App Service Plan will perform availability zone balancing.
If false, this App Service Plan will not perform availability zone balancing.
bool

HostingEnvironmentProfile

Name Description Value
id Resource ID of the App Service Environment. string

KubeEnvironmentProfile

Name Description Value
id Resource ID of the Kubernetes Environment. string

SkuDescription

Name Description Value
capabilities Capabilities of the SKU, e.g., is traffic manager enabled? Capability[]
capacity Current number of instances assigned to the resource. int
family Family code of the resource SKU. string
locations Locations of the SKU. string[]
name Name of the resource SKU. string
size Size specifier of the resource SKU. string
skuCapacity Min, max, and default scale values of the SKU. SkuCapacity
tier Service tier of the resource SKU. string

Capability

Name Description Value
name Name of the SKU capability. string
reason Reason of the SKU capability. string
value Value of the SKU capability. string

SkuCapacity

Name Description Value
default Default number of workers for this App Service plan SKU. int
elasticMaximum Maximum number of Elastic workers for this App Service plan SKU. int
maximum Maximum number of workers for this App Service plan SKU. int
minimum Minimum number of workers for this App Service plan SKU. int
scaleType Available scale configurations for an App Service plan. string

Quickstart templates

The following quickstart templates deploy this resource type.

Template Description
Function App

Deploy to Azure
This template deploy an empty Function App and a hosting plan.
App Service Quickstart - Linux App

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
App Service Quickstart - Windows app

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
App Service Quickstart - Windows container app

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
Deploy an app service with regional VNet integration

Deploy to Azure
This template allows you to deploy an app service plan and a basic Windows web app, with regional VNet integration enabled to a newly created virtual network
App Service Environment with Azure SQL backend

Deploy to Azure
This template creates an App Service Environment with an Azure SQL backend along with private endpoints along with associated resources typically used in an private/isolated environment.
App Service Environment with Hosting Plan and Azure WebApp

Deploy to Azure
Creates an App Service Environment v2 with an ILB Address in a existing virtual network that will be privately availible. The App Service Environment will contain a Hosting Plan and a Azure Web App
Create Azure App Service Environment With An Web App Added

Deploy to Azure
Creates an Azure App Service Environment inside A Virtual Network Subnet. This template also adds a Azure Web App inside the App Service Environment. Template originally authored by Callum Brankin of PixelPin
Azure Cosmos DB Account with Web App

Deploy to Azure
This template deploys an Azure Cosmos DB account, an App Service Plan, and creates a Web App in the App Service Plan. It also adds two Application settings to the Web App that reference the Azure Cosmos DB account endpoint. This way solutions deployed to the Web App can connect to the Azure Cosmos DB account endpoint using those settings.
Provision a function app running on an App Service Plan

Deploy to Azure
This template provisions a function app on a dedicated hosting plan, meaning it will be run and billed just like any App Service site.
Provision a function app on a Consumption plan

Deploy to Azure
This template provisions a function app on a Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment. There are other templates available for provisioning on a dedicated hosting plan.
Provision Consumption plan function with a Deployment Slot

Deploy to Azure
This template provisions a function app on a Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment. There are other templates available for provisioning on a dedicated hosting plan.
Provision a function app with source deployed from GitHub

Deploy to Azure
This template deploys a Function App hosted in a new dedicated App Service Plan. The Function App has a child resource that enables continous integration and deploys the function code from a GitHub repository.
Azure Function App Hosted on Dedicated Plan

Deploy to Azure
This template provisions a function app on a dedicated hosting plan, meaning it will be run and billed just like any App Service site.
Azure Function App with a Deployment Slot

Deploy to Azure
This template provisions a function app on a Premium plan with production slot and an additional deployment slot.
Azure Function App with Event Hub and Managed Identity

Deploy to Azure
his template provisions an Azure Function app on a Linux Consumption plan, along with an Event Hub, Azure Storage, and Application Insights. The function app is able to use managed identity to connect to the Event Hub and Storage account
Azure Function App Hosted on Linux Consumption Plan

Deploy to Azure
This template provisions a function app on a Linux Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment.
Function App on Linux Consumption Plan with Remote Build

Deploy to Azure
This template provisions a function app on a Linux Consumption plan and perform remote build during code deployment. The app runs on demand and you're billed per execution, with no standing resource committment.
Azure Function App Hosted on Premium Plan

Deploy to Azure
This template provisions a function app on a Premium plan.
Private Function App and private endpoint-secured Storage

Deploy to Azure
This template provisions a function app on a Premium plan that has private endpoints and communicates with Azure Storage over private endpoints.
Create Function App and private endpoint-secured Storage

Deploy to Azure
This template allows you to deploy an Azure Function App that communicates with Azure Storage over private endpoints.
Azure Function App with Virtual Network Integration

Deploy to Azure
This template provisions a function app on a Premium plan with regional virtual network integration enabled to a newly created virtual network.
Azure Function App Hosted on Windows Consumption Plan

Deploy to Azure
This template provisions a function app on a Windows Consumption plan, which is a dynamic hosting plan. The app runs on demand and you're billed per execution, with no standing resource committment.
Azure Function app and an HTTP-triggered function

Deploy to Azure
This example deploys an Azure Function app and an HTTP-triggered function inline in the template. It also deploys a Key Vault and populates a secret with the function app's host key.
Deploy an AZ enabled Azure Function Premium plan

Deploy to Azure
This template allows you to deploy an Azure Function Premium plan with availability zones support, including an availability zones enabled storage account.
Function App secured by Azure Frontdoor

Deploy to Azure
This template allows you to deploy an azure premium function protected and published by Azure Frontdoor premium. The conenction between Azure Frontdoor and Azure Functions is protected by Azure Private Link.
Deploy an Azure Function Premium plan with vnet integration

Deploy to Azure
This template allows you to deploy an Azure Function Premium plan with regional virtual network integration enabled to a newly created virtual network.
Creates a function app with managed service identity

Deploy to Azure
Creates a function app with managed service identity enabled with Application Insights set up for logs and metrics.
Provision a Mobile App with a SQL Database

Deploy to Azure
This template provisions a Mobile App, SQL Database, and Notification Hub. It configures a connection string in the mobile app for the database and notification hub.
Web App with Private Endpoint

Deploy to Azure
This template allows you to create a Web App and expose it through Private Endpoint
Application Gateway with internal API Management and Web App

Deploy to Azure
Application Gateway routing Internet traffic to a virtual network (internal mode) API Management instance which services a web API hosted in an Azure Web App.
Create an AppServicePlan and App in an ASE

Deploy to Azure
Create an AppServicePlan and App in an ASE
Create an AppServicePlan and App in an App. Service Env. v2

Deploy to Azure
Create an AppServicePlan and App in an App Service Environment v2
Create Azure Web app with Blob Storage connection string

Deploy to Azure
Creates an Azure Web app with Blob Storage connection string, Template originally authored by Jeff Bowles of Microsoft
Web App with a custom domain and optional SSL binding

Deploy to Azure
Create a web app and with a custom domain and optionally add SSL certificate for https encryption.
Web App with diagnostics logging to Blob Container

Deploy to Azure
Deploy a Web App with diagnostics logging to Storage Account Blob Container enabled.
Web App Deployment from GitHub

Deploy to Azure
This template allows you to create an WebApp linked with a GitHub Repository linked.
Create a web app on Azure with Java 13 and Tomcat 9 enabled

Deploy to Azure
This template creates a web app on azure with Java 13 and Tomcat 9 enabled allowing you to run Java applications in Azure. Template was authored by Donovan Brown of Microsoft.
Web App w/ Application Insights sending to Log Analytics

Deploy to Azure
This template will is to help support the new API versions of microsoft.insights/components. Starting with 2020-02-02-preview WorkspaceID will be required when creating Application Inisghts.This template will deploy the App Service Plan, App Service, Application Insights, Log Analytics Workspace and hook it all together.
Web App with Managed Identity, SQL Server and ΑΙ

Deploy to Azure
Simple example to deploy Azure infrastructure for app + data + managed identity + monitoring
Create a web app on Azure with Python enabled

Deploy to Azure
This template creates a web app on azure with Python enabled allowing you to run Python applications in Azure. Template was authored by Donovan Brown of Microsoft.
Create a Web App + Redis Cache + SQL DB with a template

Deploy to Azure
This template creates an Azure Web App with Redis cache and a SQL Database.
Provision a Web App with a SQL Database

Deploy to Azure
This template provisions a Web App, a SQL Database, AutoScale settings, Alert rules, and App Insights. It configures a connection string in the web app for the database.
Create a Web App protected by Application Gateway v2

Deploy to Azure
This template creates an Azure Web App with Access Restriction for an Application Gateway v2. The Application Gateway is deployed in a vNet (subnet) which has a 'Microsoft.Web' Service Endpoint enabled. The Web App restricts access to traffic from the subnet.
Create a Web App plus Redis Cache using a template

Deploy to Azure
This template creates an Azure Web App with Redis cache.
Deploy a basic Linux web app

Deploy to Azure
This template allows you to deploy an app service plan and a basic Linux web app
App Service Quickstart - Windows app

Deploy to Azure
This template is to be used with /azure/app-service/quickstart-arm-template
Web App with custom Deployment slots

Deploy to Azure
This template provides an easy way to deploy a web app with custom deployment slots on Azure Web Apps.
Airflow Docker Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy a puckel/docker-airflow image (latest tag) on a Linux Web App with Azure database for PostgreSQL
Django app

Deploy to Azure
This template allows you to create an App Service for deploying a Django app.
Flask app service

Deploy to Azure
This template allows you to create an App Service for deploying a Flask app.
Build a Web App on Linux with Azure database for MySQL

Deploy to Azure
This template provides a way to deploy Web Apps on Linux with Azure database for MySQL.
Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy Web App on Linux with Azure database for PostgreSQL(Preview).
Node App Service

Deploy to Azure
This template allows you to create an App Service for deploying a Node app.
Sonarqube Docker Web App on Linux with Azure SQL

Deploy to Azure
This template deploys Sonarqube in an Azure App Service web app Linux container using the official Sonarqube image and backed by an Azure SQL Server.
Sonarqube Docker Web App on Linux with MySQL

Deploy to Azure
This template provides a easy way to deploy a Sonarqube docker image (alpine tag) on a Linux Web App with Azure database for MySQL
Sonarqube Docker Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy a Sonarqube docker image (alpine tag) on a Linux Web App with Azure database for PostgreSQL(Preview)
SonarQube on Web App with PostgreSQL and VNet integration

Deploy to Azure
This template provides easy to deploy SonarQube to Web App on Linux with PostgreSQL Flexible Server, VNet integration and private DNS.
Web App with Azure database for MySQL

Deploy to Azure
This template provides a easy way to deploy web app on Azure App Service Web Apps with Azure database for MySQL.
Web App on Linux with PostgreSQL

Deploy to Azure
This template provides a easy way to deploy Web App on Linux with Azure database for PostgreSQL.
Highly Available Multi-region Web App

Deploy to Azure
This template allows you to create a secure, highly available, multi-region end to end solution with two web apps in different regions behind Azure Front Door
Web App with VNet Injection and Private Endpoint

Deploy to Azure
This template allows you to create a secure end to end solution with two web apps, front end and back end, front end will consume securely the back through VNet injection and Private Endpoint
Secure N-tier Web App

Deploy to Azure
This template allows you to create a secure end to end solution with two web apps with staging slots, front end and back end, front end will consume securely the back through VNet injection and Private Endpoint
ASP.NET app

Deploy to Azure
This template allows you to create an App Service for deploying a ASP.NET app.
Create a Web App, PE and Application Gateway v2

Deploy to Azure
This template creates an Azure Web App with Private endpoint in Azure Virtual Network Subnet , an Application Gateway v2. The Application Gateway is deployed in a vNet (subnet). The Web App restricts access to traffic from the subnet using private endpoint

Terraform (AzAPI provider) resource definition

The serverfarms resource type can be deployed with operations that target:

  • Resource groups

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Web/serverfarms resource, add the following Terraform to your template.

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.Web/serverfarms@2022-09-01"
  name = "string"
  location = "string"
  parent_id = "string"
  tags = {
    tagName1 = "tagValue1"
    tagName2 = "tagValue2"
  }
  body = jsonencode({
    properties = {
      elasticScaleEnabled = bool
      freeOfferExpirationTime = "string"
      hostingEnvironmentProfile = {
        id = "string"
      }
      hyperV = bool
      isSpot = bool
      isXenon = bool
      kubeEnvironmentProfile = {
        id = "string"
      }
      maximumElasticWorkerCount = int
      perSiteScaling = bool
      reserved = bool
      spotExpirationTime = "string"
      targetWorkerCount = int
      targetWorkerSizeId = int
      workerTierName = "string"
      zoneRedundant = bool
    }
    sku = {
      capabilities = [
        {
          name = "string"
          reason = "string"
          value = "string"
        }
      ]
      capacity = int
      family = "string"
      locations = [
        "string"
      ]
      name = "string"
      size = "string"
      skuCapacity = {
        default = int
        elasticMaximum = int
        maximum = int
        minimum = int
        scaleType = "string"
      }
      tier = "string"
    }
    kind = "string"
    extendedLocation = {
      name = "string"
    }
  })
}

Property values

serverfarms

Name Description Value
type The resource type "Microsoft.Web/serverfarms@2022-09-01"
name The resource name string (required)

Character limit: 1-60

Valid characters:
Alphanumeric, hyphens and Unicode characters that can be mapped to Punycode
location Resource Location. string (required)
parent_id To deploy to a resource group, use the ID of that resource group. string (required)
tags Resource tags. Dictionary of tag names and values.
sku Description of a SKU for a scalable resource. SkuDescription
kind Kind of resource. string
extendedLocation Extended Location. ExtendedLocation
properties AppServicePlan resource specific properties AppServicePlanProperties

ExtendedLocation

Name Description Value
name Name of extended location. string

AppServicePlanProperties

Name Description Value
elasticScaleEnabled ServerFarm supports ElasticScale. Apps in this plan will scale as if the ServerFarm was ElasticPremium sku bool
freeOfferExpirationTime The time when the server farm free offer expires. string
hostingEnvironmentProfile Specification for the App Service Environment to use for the App Service plan. HostingEnvironmentProfile
hyperV If Hyper-V container app service plan true, false otherwise. bool
isSpot If true, this App Service Plan owns spot instances. bool
isXenon Obsolete: If Hyper-V container app service plan true, false otherwise. bool
kubeEnvironmentProfile Specification for the Kubernetes Environment to use for the App Service plan. KubeEnvironmentProfile
maximumElasticWorkerCount Maximum number of total workers allowed for this ElasticScaleEnabled App Service Plan int
perSiteScaling If true, apps assigned to this App Service plan can be scaled independently.
If false, apps assigned to this App Service plan will scale to all instances of the plan.
bool
reserved If Linux app service plan true, false otherwise. bool
spotExpirationTime The time when the server farm expires. Valid only if it is a spot server farm. string
targetWorkerCount Scaling worker count. int
targetWorkerSizeId Scaling worker size ID. int
workerTierName Target worker tier assigned to the App Service plan. string
zoneRedundant If true, this App Service Plan will perform availability zone balancing.
If false, this App Service Plan will not perform availability zone balancing.
bool

HostingEnvironmentProfile

Name Description Value
id Resource ID of the App Service Environment. string

KubeEnvironmentProfile

Name Description Value
id Resource ID of the Kubernetes Environment. string

SkuDescription

Name Description Value
capabilities Capabilities of the SKU, e.g., is traffic manager enabled? Capability[]
capacity Current number of instances assigned to the resource. int
family Family code of the resource SKU. string
locations Locations of the SKU. string[]
name Name of the resource SKU. string
size Size specifier of the resource SKU. string
skuCapacity Min, max, and default scale values of the SKU. SkuCapacity
tier Service tier of the resource SKU. string

Capability

Name Description Value
name Name of the SKU capability. string
reason Reason of the SKU capability. string
value Value of the SKU capability. string

SkuCapacity

Name Description Value
default Default number of workers for this App Service plan SKU. int
elasticMaximum Maximum number of Elastic workers for this App Service plan SKU. int
maximum Maximum number of workers for this App Service plan SKU. int
minimum Minimum number of workers for this App Service plan SKU. int
scaleType Available scale configurations for an App Service plan. string