Microsoft.Web sites/config template reference

Template format

To create a Microsoft.Web/sites/config resource, add the following JSON to the resources section of your template.

{
  "name": "web",
  "type": "Microsoft.Web/sites/config",
  "apiVersion": "2018-11-01",
  "kind": "string",
  "properties": {
    "numberOfWorkers": "integer",
    "defaultDocuments": [
      "string"
    ],
    "netFrameworkVersion": "string",
    "phpVersion": "string",
    "pythonVersion": "string",
    "nodeVersion": "string",
    "linuxFxVersion": "string",
    "windowsFxVersion": "string",
    "requestTracingEnabled": "boolean",
    "requestTracingExpirationTime": "string",
    "remoteDebuggingEnabled": "boolean",
    "remoteDebuggingVersion": "string",
    "httpLoggingEnabled": "boolean",
    "logsDirectorySizeLimit": "integer",
    "detailedErrorLoggingEnabled": "boolean",
    "publishingUsername": "string",
    "appSettings": [
      {
        "name": "string",
        "value": "string"
      }
    ],
    "azureStorageAccounts": {},
    "connectionStrings": [
      {
        "name": "string",
        "connectionString": "string",
        "type": "string"
      }
    ],
    "handlerMappings": [
      {
        "extension": "string",
        "scriptProcessor": "string",
        "arguments": "string"
      }
    ],
    "documentRoot": "string",
    "scmType": "string",
    "use32BitWorkerProcess": "boolean",
    "webSocketsEnabled": "boolean",
    "alwaysOn": "boolean",
    "javaVersion": "string",
    "javaContainer": "string",
    "javaContainerVersion": "string",
    "appCommandLine": "string",
    "managedPipelineMode": "string",
    "virtualApplications": [
      {
        "virtualPath": "string",
        "physicalPath": "string",
        "preloadEnabled": "boolean",
        "virtualDirectories": [
          {
            "virtualPath": "string",
            "physicalPath": "string"
          }
        ]
      }
    ],
    "loadBalancing": "string",
    "experiments": {
      "rampUpRules": [
        {
          "actionHostName": "string",
          "reroutePercentage": "number",
          "changeStep": "number",
          "changeIntervalInMinutes": "integer",
          "minReroutePercentage": "number",
          "maxReroutePercentage": "number",
          "changeDecisionCallbackUrl": "string",
          "name": "string"
        }
      ]
    },
    "limits": {
      "maxPercentageCpu": "number",
      "maxMemoryInMb": "integer",
      "maxDiskSizeInMb": "integer"
    },
    "autoHealEnabled": "boolean",
    "autoHealRules": {
      "triggers": {
        "requests": {
          "count": "integer",
          "timeInterval": "string"
        },
        "privateBytesInKB": "integer",
        "statusCodes": [
          {
            "status": "integer",
            "subStatus": "integer",
            "win32Status": "integer",
            "count": "integer",
            "timeInterval": "string"
          }
        ],
        "slowRequests": {
          "timeTaken": "string",
          "count": "integer",
          "timeInterval": "string"
        }
      },
      "actions": {
        "actionType": "string",
        "customAction": {
          "exe": "string",
          "parameters": "string"
        },
        "minProcessExecutionTime": "string"
      }
    },
    "tracingOptions": "string",
    "vnetName": "string",
    "cors": {
      "allowedOrigins": [
        "string"
      ],
      "supportCredentials": "boolean"
    },
    "push": {
      "kind": "string",
      "properties": {
        "isPushEnabled": "boolean",
        "tagWhitelistJson": "string",
        "tagsRequiringAuth": "string",
        "dynamicTagsJson": "string"
      }
    },
    "apiDefinition": {
      "url": "string"
    },
    "autoSwapSlotName": "string",
    "localMySqlEnabled": "boolean",
    "managedServiceIdentityId": "integer",
    "xManagedServiceIdentityId": "integer",
    "ipSecurityRestrictions": [
      {
        "ipAddress": "string",
        "subnetMask": "string",
        "vnetSubnetResourceId": "string",
        "action": "string",
        "tag": "string",
        "priority": "integer",
        "name": "string",
        "description": "string"
      }
    ],
    "scmIpSecurityRestrictions": [
      {
        "ipAddress": "string",
        "subnetMask": "string",
        "vnetSubnetResourceId": "string",
        "action": "string",
        "tag": "string",
        "priority": "integer",
        "name": "string",
        "description": "string"
      }
    ],
    "scmIpSecurityRestrictionsUseMain": "boolean",
    "http20Enabled": "boolean",
    "minTlsVersion": "string",
    "ftpsState": "string",
    "reservedInstanceCount": "integer"
  }
}

Property values

The following tables describe the values you need to set in the schema.

Microsoft.Web/sites/config object

Name Type Required Value
name string Yes web
-or-
{site-name}/web
type enum Yes config
-or-
Microsoft.Web/sites/config

See Set name and type for child resources.
apiVersion enum Yes 2018-11-01
kind string No Kind of resource.
properties object Yes Core resource properties - SiteConfig object

SiteConfig object

Name Type Required Value
numberOfWorkers integer No Number of workers.
defaultDocuments array No Default documents. - string
netFrameworkVersion string No .NET Framework version.
phpVersion string No Version of PHP.
pythonVersion string No Version of Python.
nodeVersion string No Version of Node.js.
linuxFxVersion string No Linux App Framework and version
windowsFxVersion string No Xenon App Framework and version
requestTracingEnabled boolean No true if request tracing is enabled; otherwise, false.
requestTracingExpirationTime string No Request tracing expiration time.
remoteDebuggingEnabled boolean No true if remote debugging is enabled; otherwise, false.
remoteDebuggingVersion string No Remote debugging version.
httpLoggingEnabled boolean No true if HTTP logging is enabled; otherwise, false.
logsDirectorySizeLimit integer No HTTP logs directory size limit.
detailedErrorLoggingEnabled boolean No true if detailed error logging is enabled; otherwise, false.
publishingUsername string No Publishing user name.
appSettings array No Application settings. - NameValuePair object
azureStorageAccounts object No User-provided Azure storage accounts.
connectionStrings array No Connection strings. - ConnStringInfo object
handlerMappings array No Handler mappings. - HandlerMapping object
documentRoot string No Document root.
scmType enum No SCM type. - None, Dropbox, Tfs, LocalGit, GitHub, CodePlexGit, CodePlexHg, BitbucketGit, BitbucketHg, ExternalGit, ExternalHg, OneDrive, VSO
use32BitWorkerProcess boolean No true to use 32-bit worker process; otherwise, false.
webSocketsEnabled boolean No true if WebSocket is enabled; otherwise, false.
alwaysOn boolean No true if Always On is enabled; otherwise, false.
javaVersion string No Java version.
javaContainer string No Java container.
javaContainerVersion string No Java container version.
appCommandLine string No App command line to launch.
managedPipelineMode enum No Managed pipeline mode. - Integrated or Classic
virtualApplications array No Virtual applications. - VirtualApplication object
loadBalancing enum No Site load balancing. - WeightedRoundRobin, LeastRequests, LeastResponseTime, WeightedTotalTraffic, RequestHash
experiments object No This is work around for polymorphic types. - Experiments object
limits object No Site limits. - SiteLimits object
autoHealEnabled boolean No true if Auto Heal is enabled; otherwise, false.
autoHealRules object No Auto Heal rules. - AutoHealRules object
tracingOptions string No Tracing options.
vnetName string No Virtual Network name.
cors object No Cross-Origin Resource Sharing (CORS) settings. - CorsSettings object
push object No Push endpoint settings. - PushSettings object
apiDefinition object No Information about the formal API definition for the app. - ApiDefinitionInfo object
autoSwapSlotName string No Auto-swap slot name.
localMySqlEnabled boolean No true to enable local MySQL; otherwise, false.
managedServiceIdentityId integer No Managed Service Identity Id
xManagedServiceIdentityId integer No Explicit Managed Service Identity Id
ipSecurityRestrictions array No IP security restrictions for main. - IpSecurityRestriction object
scmIpSecurityRestrictions array No IP security restrictions for scm. - IpSecurityRestriction object
scmIpSecurityRestrictionsUseMain boolean No IP security restrictions for scm to use main.
http20Enabled boolean No Http20Enabled: configures a web site to allow clients to connect over http2.0
minTlsVersion enum No MinTlsVersion: configures the minimum version of TLS required for SSL requests. - 1.0, 1.1, 1.2
ftpsState enum No State of FTP / FTPS service. - AllAllowed, FtpsOnly, Disabled
reservedInstanceCount integer No Number of reserved instances.This setting only applies to the Consumption Plan

NameValuePair object

Name Type Required Value
name string No Pair name.
value string No Pair value.

ConnStringInfo object

Name Type Required Value
name string No Name of connection string.
connectionString string No Connection string value.
type enum No Type of database. - MySql, SQLServer, SQLAzure, Custom, NotificationHub, ServiceBus, EventHub, ApiHub, DocDb, RedisCache, PostgreSQL

HandlerMapping object

Name Type Required Value
extension string No Requests with this extension will be handled using the specified FastCGI application.
scriptProcessor string No The absolute path to the FastCGI application.
arguments string No Command-line arguments to be passed to the script processor.

VirtualApplication object

Name Type Required Value
virtualPath string No Virtual path.
physicalPath string No Physical path.
preloadEnabled boolean No true if preloading is enabled; otherwise, false.
virtualDirectories array No Virtual directories for virtual application. - VirtualDirectory object

Experiments object

Name Type Required Value
rampUpRules array No List of ramp-up rules. - RampUpRule object

SiteLimits object

Name Type Required Value
maxPercentageCpu number No Maximum allowed CPU usage percentage.
maxMemoryInMb integer No Maximum allowed memory usage in MB.
maxDiskSizeInMb integer No Maximum allowed disk size usage in MB.

AutoHealRules object

Name Type Required Value
triggers object No Conditions that describe when to execute the auto-heal actions. - AutoHealTriggers object
actions object No Actions to be executed when a rule is triggered. - AutoHealActions object

CorsSettings object

Name Type Required Value
allowedOrigins array No Gets or sets the list of origins that should be allowed to make cross-origincalls (for example: http://example.com:12345). Use "*" to allow all. - string
supportCredentials boolean No Gets or sets whether CORS requests with credentials are allowed. See https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS#Requests_with_credentialsfor more details.

PushSettings object

Name Type Required Value
kind string No Kind of resource.
properties object No PushSettings resource specific properties - PushSettingsProperties object

ApiDefinitionInfo object

Name Type Required Value
url string No The URL of the API definition.

IpSecurityRestriction object

Name Type Required Value
ipAddress string No IP address the security restriction is valid for.It can be in form of pure ipv4 address (required SubnetMask property) orCIDR notation such as ipv4/mask (leading bit match). For CIDR,SubnetMask property must not be specified.
subnetMask string No Subnet mask for the range of IP addresses the restriction is valid for.
vnetSubnetResourceId string No Virtual network resource id
action string No Allow or Deny access for this IP range.
tag enum No Defines what this IP filter will be used for. This is to support IP filtering on proxies. - Default or XffProxy
priority integer No Priority of IP restriction rule.
name string No IP restriction rule name.
description string No IP restriction rule description.

VirtualDirectory object

Name Type Required Value
virtualPath string No Path to virtual application.
physicalPath string No Physical path.

RampUpRule object

Name Type Required Value
actionHostName string No Hostname of a slot to which the traffic will be redirected if decided to. E.g. myapp-stage.azurewebsites.net.
reroutePercentage number No Percentage of the traffic which will be redirected to ActionHostName.
changeStep number No In auto ramp up scenario this is the step to add/remove from ReroutePercentage until it reaches MinReroutePercentage or MaxReroutePercentage. Site metrics are checked every N minutes specified in ChangeIntervalInMinutes.Custom decision algorithm can be provided in TiPCallback site extension which URL can be specified in ChangeDecisionCallbackUrl.
changeIntervalInMinutes integer No Specifies interval in minutes to reevaluate ReroutePercentage.
minReroutePercentage number No Specifies lower boundary above which ReroutePercentage will stay.
maxReroutePercentage number No Specifies upper boundary below which ReroutePercentage will stay.
changeDecisionCallbackUrl string No Custom decision algorithm can be provided in TiPCallback site extension which URL can be specified. See TiPCallback site extension for the scaffold and contracts.https://www.siteextensions.net/packages/TiPCallback/
name string No Name of the routing rule. The recommended name would be to point to the slot which will receive the traffic in the experiment.

AutoHealTriggers object

Name Type Required Value
requests object No A rule based on total requests. - RequestsBasedTrigger object
privateBytesInKB integer No A rule based on private bytes.
statusCodes array No A rule based on status codes. - StatusCodesBasedTrigger object
slowRequests object No A rule based on request execution time. - SlowRequestsBasedTrigger object

AutoHealActions object

Name Type Required Value
actionType enum No Predefined action to be taken. - Recycle, LogEvent, CustomAction
customAction object No Custom action to be taken. - AutoHealCustomAction object
minProcessExecutionTime string No Minimum time the process must executebefore taking the action

PushSettingsProperties object

Name Type Required Value
isPushEnabled boolean Yes Gets or sets a flag indicating whether the Push endpoint is enabled.
tagWhitelistJson string No Gets or sets a JSON string containing a list of tags that are whitelisted for use by the push registration endpoint.
tagsRequiringAuth string No Gets or sets a JSON string containing a list of tags that require user authentication to be used in the push registration endpoint.Tags can consist of alphanumeric characters and the following:'_', '@', '#', '.', ':', '-'. Validation should be performed at the PushRequestHandler.
dynamicTagsJson string No Gets or sets a JSON string containing a list of dynamic tags that will be evaluated from user claims in the push registration endpoint.

RequestsBasedTrigger object

Name Type Required Value
count integer No Request Count.
timeInterval string No Time interval.

StatusCodesBasedTrigger object

Name Type Required Value
status integer No HTTP status code.
subStatus integer No Request Sub Status.
win32Status integer No Win32 error code.
count integer No Request Count.
timeInterval string No Time interval.

SlowRequestsBasedTrigger object

Name Type Required Value
timeTaken string No Time taken.
count integer No Request Count.
timeInterval string No Time interval.

AutoHealCustomAction object

Name Type Required Value
exe string No Executable to be run.
parameters string No Parameters for the executable.

Quickstart templates

The following quickstart templates deploy this resource type.

Template Description
Provision a function app on a dedicated hosting 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. There are other templates available for provisioning on a dynamic hosting plan.
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
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
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)
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.
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
Create Azure Web app with GoLang extension

Deploy to Azure
Creates an Azure Web app with Golang extension, Template and Golang Extension originally authored by Wade Wegner of Microsoft
Application Gateway for a Web App with IP Restriction

Deploy to Azure
This template creates an application gateway in front of an Azure Web App with IP restriction enabled on the Web App.
Call custom APIs from Azure Logic Apps

Deploy to Azure
Although Logic Apps provides hundreds of connectors for various services, you might want to call APIs that run your own code. One of the easiest and most scalable ways to host your own web APIs is by using Azure App Service. This template deploys a Web app for your custom API and secures that API by using Azure Active Directory authentication.
WebApp consuming a Azure SQL Private Endpoint

Deploy to Azure
This template shows how to create a Web app that consumes a private endpoint pointing to Azure SQL Server
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
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.
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 plus Redis Cache using a template

Deploy to Azure
This template creates an Azure Web App with Redis cache.
Web App with diagnostics logging to Blob Container

Deploy to Azure
Deploy a Web App with diagnostics logging to Storage Account Blob Container enabled.
Airflow Web App with PostgreSQL database on App Services

Deploy to Azure
A template for deploying Airflow Web App with PostgreSQL database on App Services
Enterprise Governance-AppService, SQL DB, AD, OMS, Runbooks

Deploy to Azure
Cloud adoption for an Enterprise, small or large, require responsible and efficient governance models to derive value from their cloud deployments. CloudWise (a code-name for the solution), is a composite solution available from Azure Partner QuickStarts, is an adoption enabler for Customers, System Integrators and Partners alike, that delivers a self-serviceable, automated governance and operations solution, focused on Optimizing Your Costs, Improve Your Application(s) Reliability, Reducing Business Risk. The solution highlights the core governance pillars of Visibility and Control.
EPiserverCMS in Azure

Deploy to Azure
This template allows you to create resources required for EpiServerCMS deployment in Azure
Java CI/CD using Jenkins and Azure Web Apps

Deploy to Azure
This is a sample for Java CI/CD using Jenkins and Azure Web Apps.
Orchard CMS Video Portal Web App

Deploy to Azure
This template provides a easy way to deploy Orchard CMS on Azure App Service Web Apps with the Azure Media Services module enabled and configured.
PubNub Realtime Gateway for Azure Event Hubs

Deploy to Azure
The PubNub Realtime Gateway for Azure provides a realtime data stream bridge between the PubNub Data Stream Network and Azure Event Hubs. -- consider it a bi-directional bridge between PubNub and Azure!
Scalable Umbraco CMS Web App

Deploy to Azure
This template provides a easy way to deploy umbraco CMS web app on Azure App Service Web Apps.
Simple Umbraco CMS Web App

Deploy to Azure
This template provides a easy way to deploy umbraco CMS web app on Azure App Service Web Apps.
WordPress on App Service with MySQL In App

Deploy to Azure
This template deploys a WordPress Web App on a Windows App Service with MySQL in app