Azure App Service (Web Apps) Windows Web App
This page shows how to write Terraform and Azure Resource Manager for App Service (Web Apps) Windows Web App and write them securely.
azurerm_windows_web_app (Terraform)
The Windows Web App in App Service (Web Apps) can be configured in Terraform with the resource name azurerm_windows_web_app. The following sections describe how to use the resource and its parameters.
Example Usage from GitHub
An example could not be found in GitHub.
Parameters
The following arguments are supported:
location- (Required) The Azure Region where the Windows Web App should exist. Changing this forces a new Windows Web App to be created.name- (Required) The name which should be used for this Windows Web App. Changing this forces a new Windows Web App to be created.resource_group_name- (Required) The name of the Resource Group where the Windows Web App should exist. Changing this forces a new Windows Web App to be created.service_plan_id- (Required) The ID of the Service Plan that this Windows App Service will be created in.site_config- (Required) Asite_configblock as defined below.
app_settings- (Optional) A map of key-value pairs of App Settings.auth_settings- (Optional) Anauth_settingsblock as defined below.backup- (Optional) Abackupblock as defined below.client_affinity_enabled- (Optional) Should Client Affinity be enabled?client_cert_enabled- (Optional) Should Client Certificates be enabled?client_cert_mode- (Optional) The Client Certificate mode. Possible values includeOptionalandRequired. This property has no effect whenclient_cert_enabledisfalseconnection_string- (Optional) One or moreconnection_stringblocks as defined below.enabled- (Optional) Should the Windows Web App be enabled? Defaults totrue.https_only- (Optional) Should the Windows Web App require HTTPS connections.identity- (Optional) Anidentityblock as defined below.logs- (Optional) Alogsblock as defined below.storage_account- (Optional) One or morestorage_accountblocks as defined below.tags- (Optional) A mapping of tags which should be assigned to the Windows Web App.
A action block supports the following:
action_type- (Required) Predefined action to be taken to an Auto Heal trigger. Possible values include:Recycle,LogEvent, andCustomAction.custom_action- (Optional) Acustom_actionblock as defined below.minimum_process_execution_time- (Optional) The minimum amount of time inhh:mm:ssthe Windows Web App must have been running before the defined action will be run in the event of a trigger.
A active_directory block supports the following:
client_id- (Required) The ID of the Client to use to authenticate with Azure Active Directory.allowed_audiences- (Optional) Specifies a list of Allowed audience values to consider when validating JWTs issued by Azure Active Directory.
Note: The
client_idvalue is always considered an allowed audience.
client_secret- (Optional) The Client Secret for the Client ID. Cannot be used withclient_secret_setting_name.client_secret_setting_name- (Optional) The App Setting name that contains the client secret of the Client. Cannot be used withclient_secret.
A application_logs block supports the following:
azure_blob_storage- (Optional) Anazure_blob_storageblock as defined below.file_system_level- (Optional) Log level. Possible values include:Verbose,Information,Warning, andError.
A application_stack block supports the following:
current_stack- (Optional) The Application Stack for the Windows Web App. Possible values includedotnet,node,python,php, andjava.
NOTE: Whilst this property is Optional omitting it can cause unexpected behaviour, in particular for display of settings in the Azure Portal.
docker_container_name- (Optional) The name of the Docker Container. For exampleazure-app-service/samples/aspnethelloworlddocker_container_registry- (Optional) The registry Host on which the specified Docker Container can be located. For examplemcr.microsoft.comdocker_container_tag- (Optional) The Image Tag of the specified Docker Container to use. For examplelatestdotnet_version- (Optional) The version of .Net to use whencurrent_stackis set todotnet. Possible values includev2.0,v3.0,v4.0, andv5.0.java_container- (Optional) The Java container type to use whencurrent_stackis set tojava. Possible values includeJAVA,JETTY, andTOMCAT. Required withjava_versionandjava_container_version.java_container_version- (Optional) The Version of thejava_containerto use. Required withjava_versionandjava_container.java_version- (Optional) The version of Java to use whencurrent_stackis set tojava. Possible values include1.7,1.8and11. Required withjava_containerandjava_container_version.
NOTE: For compatible combinations of
java_version,java_containerandjava_container_versionusers can useaz webapp list-runtimesfrom command line.
node_version- (Optional) The version of node to use whencurrent_stackis set tonode.
NOTE: This property conflicts with
java_version.
php_version- (Optional) The version of PHP to use whencurrent_stackis set tophp. Possible values includev5.6,v7.3, andv7.4.python_version- (Optional) The version of Python to use whencurrent_stackis set topython. Possible values include2.7and3.4.0.
A auth_settings block supports the following:
enabled- (Required) Should the Authentication / Authorization feature is enabled for the Windows Web App be enabled?active_directory- (Optional) Anactive_directoryblock as defined above.additional_login_params- (Optional) Specifies a map of Login Parameters to send to the OpenID Connect authorization endpoint when a user logs in.allowed_external_redirect_urls- (Optional) Specifies a list of External URLs that can be redirected to as part of logging in or logging out of the Windows Web App.default_provider- (Optional) The default authentication provider to use when multiple providers are configured. Possible values include:BuiltInAuthenticationProviderAzureActiveDirectory,BuiltInAuthenticationProviderFacebook,BuiltInAuthenticationProviderGoogle,BuiltInAuthenticationProviderMicrosoftAccount,BuiltInAuthenticationProviderTwitter,BuiltInAuthenticationProviderGithub
NOTE: This setting is only needed if multiple providers are configured, and the
unauthenticated_client_actionis set to "RedirectToLoginPage".
facebook- (Optional) Afacebookblock as defined below.github- (Optional) Agithubblock as defined below.google- (Optional) Agoogleblock as defined below.issuer- (Optional) The OpenID Connect Issuer URI that represents the entity which issues access tokens for this Windows Web App.
NOTE: When using Azure Active Directory, this value is the URI of the directory tenant, e.g. https://sts.windows.net/[tenant-guid]/.
microsoft- (Optional) Amicrosoftblock as defined below.runtime_version- (Optional) The RuntimeVersion of the Authentication / Authorization feature in use for the Windows Web App.token_refresh_extension_hours- (Optional) The number of hours after session token expiration that a session token can be used to call the token refresh API. Defaults to72hours.token_store_enabled- (Optional) Should the Windows Web App durably store platform-specific security tokens that are obtained during login flows? Defaults tofalse.twitter- (Optional) Atwitterblock as defined below.unauthenticated_client_action- (Optional) The action to take when an unauthenticated client attempts to access the app. Possible values include:RedirectToLoginPage,AllowAnonymous.
A auto_heal_setting block supports the following:
action- (Required) Anactionblock as defined above.trigger- (Required) Atriggerblock as defined below.
A azure_blob_storage block supports the following:
retention_in_days- (Required) The time in days after which to remove blobs. A value of0means no retention.sas_url- (Required) SAS url to an Azure blob container with read/write/list/delete permissions.
A backup block supports the following:
name- (Required) The name which should be used for this Backup.schedule- (Required) Ascheduleblock as defined below.storage_account_url- (Required) The SAS URL to the container.enabled- (Optional) Should this backup job be enabled?
A connection_string block supports the following:
type- (Required) Type of database. Possible values include:MySQL,SQLServer,SQLAzure,Custom,NotificationHub,ServiceBus,EventHub,APIHub,DocDb,RedisCache, andPostgreSQL.value- (Required) The connection string value.
A cors block supports the following:
allowed_origins- (Required) Specifies a list of origins that should be allowed to make cross-origin calls.support_credentials- (Optional) Whether CORS requests with credentials are allowed. Defaults tofalse
A custom_action block supports the following:
executable- (Required) The executable to run for thecustom_action.parameters- (Optional) The parameters to pass to the specifiedexecutable.
A facebook block supports the following:
app_id- (Required) The App ID of the Facebook app used for login.app_secret- (Optional) The App Secret of the Facebook app used for Facebook Login. Cannot be specified withapp_secret_setting_name.app_secret_setting_name- (Optional) The app setting name that contains theapp_secretvalue used for Facebook Login. Cannot be specified withapp_secret.oauth_scopes- (Optional) Specifies a list of OAuth 2.0 scopes to be requested as part of Facebook Login authentication.
A file_system block supports the following:
retention_in_days- (Required) The retention period in days. A values of0means no retention.retention_in_mb- (Required) The maximum size in megabytes that log files can use.
A github block supports the following:
client_id- (Required) The ID of the GitHub app used for login.client_secret- (Optional) The Client Secret of the GitHub app used for GitHub Login. Cannot be specified withclient_secret_setting_name.client_secret_setting_name- (Optional) The app setting name that contains theclient_secretvalue used for GitHub Login. Cannot be specified withclient_secret.oauth_scopes- (Optional) Specifies a list of OAuth 2.0 scopes that will be requested as part of GitHub Login authentication.
A google block supports the following:
client_id- (Required) The OpenID Connect Client ID for the Google web application.client_secret- (Optional) The client secret associated with the Google web application. Cannot be specified withclient_secret_setting_name.client_secret_setting_name- (Optional) The app setting name that contains theclient_secretvalue used for Google Login. Cannot be specified withclient_secret.oauth_scopes- (Optional) Specifies a list of OAuth 2.0 scopes that will be requested as part of Google Sign-In authentication. If not specified, "openid", "profile", and "email" are used as default scopes.
A headers block supports the following:
NOTE: Please see the official Azure Documentation for details on using header filtering.
x_azure_fdid- (Optional) Specifies a list of Azure Front Door IDs.x_fd_health_probe- (Optional) Specifies if a Front Door Health Probe should be expected.x_forwarded_for- (Optional) Specifies a list of addresses for which matching should be applied. Omitting this value means allow any.x_forwarded_host- (Optional) Specifies a list of Hosts for which matching should be applied.
A http_logs block supports the following:
azure_blob_storage- (Optional) Aazure_blob_storageblock as defined above.file_system- (Optional) Afile_systemblock as defined above.
A identity block supports the following:
type- (Required) The type of managed service identity. Possible values include:ManagedServiceIdentityTypeSystemAssigned,ManagedServiceIdentityTypeUserAssigned, andManagedServiceIdentityTypeSystemAssignedUserAssigned.identity_ids- (Optional) Specifies a list of Identity IDs.
A ip_restriction block supports the following:
action- (Optional) The action to take. Possible values areAlloworDeny.headers- (Optional) Aheadersblock as defined above.ip_address- (Optional) The CIDR notation of the IP or IP Range to match. For example:10.0.0.0/24or192.168.10.1/32name- (Optional) The name which should be used for thisip_restriction.priority- (Optional) The priority value of thisip_restriction.service_tag- (Optional) The Service Tag used for this IP Restriction.virtual_network_subnet_id- (Optional) The Virtual Network Subnet ID used for this IP Restriction.
NOTE: One and only one of
ip_address,service_tagorvirtual_network_subnet_idmust be specified.
A logs block supports the following:
application_logs- (Optional) Aapplication_logsblock as defined above.detailed_error_messages- (Optional) Should detailed error messages be enabled.failed_request_tracing- (Optional) Should tracing be enabled for failed requests.http_logs- (Optional) Ahttp_logsblock as defined above.
A microsoft block supports the following:
client_id- (Required) The OAuth 2.0 client ID that was created for the app used for authentication.client_secret- (Optional) The OAuth 2.0 client secret that was created for the app used for authentication. Cannot be specified withclient_secret_setting_name.client_secret_setting_name- (Optional) The app setting name containing the OAuth 2.0 client secret that was created for the app used for authentication. Cannot be specified withclient_secret.oauth_scopes- (Optional) Specifies a list of OAuth 2.0 scopes that will be requested as part of Microsoft Account authentication. If not specified, "wl.basic" is used as the default scope.
A requests block supports the following:
count- (Required) The number of requests in the specifiedintervalto trigger this rule.interval- (Required) The interval inhh:mm:ss.
A schedule block supports the following:
frequency_interval- (Required) How often the backup should be executed (e.g. for weekly backup, this should be set to7andfrequency_unitshould be set toDay).
NOTE: Not all intervals are supported on all Windows Web App SKU's. Please refer to the official documentation for appropriate values.
frequency_unit- (Required) The unit of time for how often the backup should take place. Possible values include:Day,Hourkeep_at_least_one_backup- (Optional) Should the service keep at least one backup, regardless of age of backup. Defaults tofalse.retention_period_days- (Optional) After how many days backups should be deleted.start_time- (Optional) When the schedule should start working in RFC-3339 format.
A scm_ip_restriction block supports the following:
action- (Optional) The action to take. Possible values areAlloworDeny.headers- (Optional) Aheadersblock as defined above.ip_address- (Optional) The CIDR notation of the IP or IP Range to match. For example:10.0.0.0/24or192.168.10.1/32name- (Optional) The name which should be used for thisip_restriction.priority- (Optional) The priority value of thisip_restriction.service_tag- (Optional) The Service Tag used for this IP Restriction.virtual_network_subnet_id- (Optional) The Virtual Network Subnet ID used for this IP Restriction.
NOTE: One and only one of
ip_address,service_tagorvirtual_network_subnet_idmust be specified.
A site_config block supports the following:
always_on- (Optional) If this Windows Web App is Always On enabled. Defaults tofalse.api_management_config_id- (Optional) The ID of the APIM configuration for this Windows Web App.app_command_line- (Optional) The App command line to launch.application_stack- (Optional) Aapplication_stackblock as defined above.auto_heal- (Optional) Should Auto heal rules be enabled. Required withauto_heal_setting.auto_heal_setting- (Optional) Aauto_heal_settingblock as defined above. Required withauto_heal.auto_swap_slot_name- (Optional) The Windows Web App Slot Name to automatically swap to when deployment to that slot is successfully completed.cors- (Optional) Acorsblock as defined above.default_documents- (Optional) Specifies a list of Default Documents for the Windows Web App.ftps_state- (Optional) The State of FTP / FTPS service. Possible values include:AllAllowed,FtpsOnly,Disabled.
NOTE: Azure defaults this value to
AllAllowed, however, in the interests of security Terraform will default this toDisabledto ensure the user makes a conscious choice to enable it.
health_check_path- (Optional) The path to the Health Check.health_check_eviction_time_in_min- (Optional) The amount of time in minutes that a node can be unhealthy before being removed from the load balancer. Possible values are between2and10. Only valid in conjunction withhealth_check_path.http2_enabled- (Optional) Should the HTTP2 be enabled?ip_restriction- (Optional) One or moreip_restrictionblocks as defined above.load_balancing_mode- (Optional) The Site load balancing. Possible values include:WeightedRoundRobin,LeastRequests,LeastResponseTime,WeightedTotalTraffic,RequestHash,PerSiteRoundRobin. Defaults toLeastRequestsif omitted.local_mysql- (Optional) Use Local MySQL. Defaults tofalse.managed_pipeline_mode- (Optional) Managed pipeline mode. Possible values include:Integrated,Classic.minimum_tls_version- (Optional) The configures the minimum version of TLS required for SSL requests. Possible values include:1.0,1.1, and1.2. Defaults to1.2.number_of_workers- (Optional) The number of Workers for this Windows App Service.remote_debugging- (Optional) Should Remote Debugging be enabled. Defaults tofalse.remote_debugging_version- (Optional) The Remote Debugging Version. Possible values includeVS2017andVS2019scm_ip_restriction- (Optional) One or morescm_ip_restrictionblocks as defined above.scm_minimum_tls_version- (Optional) The configures the minimum version of TLS required for SSL requests to the SCM site Possible values include:1.0,1.1, and1.2. Defaults to1.2.scm_use_main_ip_restriction- (Optional) Should the Windows Web Appip_restrictionconfiguration be used for the SCM also.32_bit_worker- (Optional) Should the Windows Web App use a 32-bit worker.virtual_application- (Optional) One or morevirtual_applicationblocks as defined below.websockets- (Optional) Should Web Sockets be enabled. Defaults tofalse.
A slow_request block supports the following:
count- (Required) The number of Slow Requests in the timeintervalto trigger this rule.interval- (Required) The time interval in the formhh:mm:ss.time_taken- (Required) The threshold of time passed to qualify as a Slow Request inhh:mm:ss.path- (Optional) The path for which this slow request rule applies.
A status_code block supports the following:
count- (Required) The number of occurrences of the definedstatus_codein the specifiedintervalon which to trigger this rule.interval- (Required) The time interval in the formhh:mm:ss.status_code_range- (Required) The status code for this rule, accepts single status codes and status code ranges. e.g.500or400-499. Possible values are integers between101and599path- (Optional) The path to which this rule status code applies.sub_status- (Optional) The Request Sub Status of the Status Code.win32_status- (Optional) The Win32 Status Code of the Request.
A storage_account block supports the following:
access_key- (Required) The Access key for the storage account.account_name- (Required) The Name of the Storage Account.name- (Required) The name which should be used for this TODO.share_name- (Required) The Name of the File Share or Container Name for Blob storage.type- (Required) The Azure Storage Type. Possible values includeAzureFilesandAzureBlobmount_path- (Optional) The path at which to mount the storage share.
A trigger block supports the following:
private_memory_kb- (Optional) The amount of Private Memory to be consumed for this rule to trigger. Possible values are between102400and13631488.requests- (Optional) Arequestsblock as defined above.slow_request- (Optional) One or moreslow_requestblocks as defined above.status_code- (Optional) One or morestatus_codeblocks as defined above.
A twitter block supports the following:
consumer_key- (Required) The OAuth 1.0a consumer key of the Twitter application used for sign-in.consumer_secret- (Optional) The OAuth 1.0a consumer secret of the Twitter application used for sign-in. Cannot be specified withconsumer_secret_setting_name.consumer_secret_setting_name- (Optional) The app setting name that contains the OAuth 1.0a consumer secret of the Twitter application used for sign-in. Cannot be specified withconsumer_secret.
A virtual_application block supports the following:
physical_path- (Required) The physical path for the Virtual Application.preload- (Required) Should pre-loading be enabled. Defaults tofalse.virtual_directory- (Optional) One or morevirtual_directoryblocks as defined below.virtual_path- (Required) The Virtual Path for the Virtual Application.
A virtual_directory block supports the following:
physical_path- (Optional) The physical path for the Virtual Application.virtual_path- (Optional) The Virtual Path for the Virtual Application.
In addition to the Arguments listed above - the following Attributes are exported:
id- The ID of the Windows Web App.custom_domain_verification_id- The identifier used by App Service to perform domain ownership verification via DNS TXT record.default_hostname- The default hostname of the Windows Web App.kind- The Kind value for this Windows Web App.outbound_ip_address_list- A list of outbound IP addresses - such as["52.23.25.3", "52.143.43.12"]outbound_ip_addresses- A comma separated list of outbound IP addresses - such as52.23.25.3,52.143.43.12.possible_outbound_ip_address_list- Apossible_outbound_ip_address_listblock as defined below.possible_outbound_ip_addresses- A comma separated list of outbound IP addresses - such as52.23.25.3,52.143.43.12,52.143.43.17- not all of which are necessarily in use. Superset ofoutbound_ip_addresses.site_credential- Asite_credentialblock as defined below.
A site_credential block exports the following:
name- The Site Credentials Username used for publishing.password- The Site Credentials Password used for publishing.
Explanation in Terraform Registry
Manages a Windows Web App. !> Note: This Resource is coming in version 3.0 of the Azure Provider and is available as an opt-in Beta - more information can be found in the upcoming version 3.0 of the Azure Provider.
Tips: Best Practices for The Other Azure App Service (Web Apps) Resources
In addition to the azurerm_app_service, Azure App Service (Web Apps) has the other resources that should be configured for security reasons. Please check some examples of those resources and precautions.
azurerm_app_service
Ensure your App Service is accessible via HTTPS only
It is better to configure the App Service to be accessible via HTTPS only. By default, both HTTP and HTTPS are available.
azurerm_function_app
Ensure to enable authentication to prevent anonymous request being accepted
It is better to enable authentication to prevent anonymous requests and ensure all communications in the application are authenticated.
Microsoft.Web/sites (Azure Resource Manager)
The sites in Microsoft.Web can be configured in Azure Resource Manager with the resource name Microsoft.Web/sites. The following sections describe how to use the resource and its parameters.
Example Usage from GitHub
"ResourceType": "Microsoft.Web/sites",
"MetricName": "Http5xx",
"Operator": "GreaterThanOrEqual",
"Threshold": "50",
"TimeWindow": "PT5M",
"Aggregation": "Total"
"resourceType": "Microsoft.Web/sites",
"allOf": [
{
"path": "kind",
"regex": "api$"
},
"type": "Microsoft.Web/sites",
"apiVersion": "2018-11-01",
"name": "[parameters('FunctionAppName')]",
"location": "UK South",
"kind": "functionapp",
"properties": {
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"deploymentId": {
"type": "Microsoft.Web/sites",
"name": "[parameters('site_name')]",
"apiVersion": "2016-08-01",
"location": "[resourceGroup().location]",
"scale": null,
"properties": {
"type": "Microsoft.Web/sites",
"apiVersion": "2018-11-01",
"name": "[parameters('sites_chapter4_iac_dockerimage_name')]",
"location": "Central US",
"dependsOn": [
"[resourceId('Microsoft.Web/serverfarms', parameters('serverfarms_ASP_Chapter4RG_ac17_name'))]"
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"infrastructure": {
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"infrastructure": {
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"infrastructure": {
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"infrastructure": {
Parameters
apiVersionrequired - stringextendedLocationoptionalnameoptional - stringName of extended location.
identityoptionaltypeoptional - stringType of managed service identity.
userAssignedIdentitiesoptional - undefinedThe list of user assigned identities associated with the resource. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}
kindoptional - stringKind of resource.
locationrequired - stringResource Location.
namerequired - stringUnique name of the app to create or update. To create or update a deployment slot, use the {slot} parameter.
propertiesrequiredclientAffinityEnabledoptional - boolean<code>true</code> to enable client affinity; <code>false</code> to stop sending session affinity cookies, which route client requests in the same session to the same instance. Default is <code>true</code>.
clientCertEnabledoptional - boolean<code>true</code> to enable client certificate authentication (TLS mutual authentication); otherwise, <code>false</code>. Default is <code>false</code>.
clientCertExclusionPathsoptional - stringclient certificate authentication comma-separated exclusion paths
clientCertModeoptional - stringThis composes with ClientCertEnabled setting.
- ClientCertEnabled: false means ClientCert is ignored.
- ClientCertEnabled: true and ClientCertMode: Required means ClientCert is required.
- ClientCertEnabled: true and ClientCertMode: Optional means ClientCert is optional or accepted.
cloningInfooptionalappSettingsOverridesoptional - stringApplication setting overrides for cloned app. If specified, these settings override the settings cloned from source app. Otherwise, application settings from source app are retained.
cloneCustomHostNamesoptional - boolean<code>true</code> to clone custom hostnames from source app; otherwise, <code>false</code>.
cloneSourceControloptional - boolean<code>true</code> to clone source control from source app; otherwise, <code>false</code>.
configureLoadBalancingoptional - boolean<code>true</code> to configure load balancing for source and destination app.
correlationIdoptional - stringCorrelation ID of cloning operation. This ID ties multiple cloning operations together to use the same snapshot.
hostingEnvironmentoptional - stringApp Service Environment.
overwriteoptional - boolean<code>true</code> to overwrite destination app; otherwise, <code>false</code>.
sourceWebAppIdrequired - stringARM resource ID of the source app. App resource ID is of the form /subscriptions/{subId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{siteName} for production slots and /subscriptions/{subId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{siteName}/slots/{slotName} for other slots.
sourceWebAppLocationoptional - stringLocation of source app ex: West US or North Europe
trafficManagerProfileIdoptional - stringARM resource ID of the Traffic Manager profile to use, if it exists. Traffic Manager resource ID is of the form /subscriptions/{subId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/trafficManagerProfiles/{profileName}.
trafficManagerProfileNameoptional - stringName of Traffic Manager profile to create. This is only needed if Traffic Manager profile does not already exist.
containerSizeoptional - integerSize of the function container.
customDomainVerificationIdoptional - stringUnique identifier that verifies the custom domains assigned to the app. Customer will add this id to a txt record for verification.
dailyMemoryTimeQuotaoptional - integerMaximum allowed daily memory-time quota (applicable on dynamic apps only).
enabledoptional - boolean<code>true</code> if the app is enabled; otherwise, <code>false</code>. Setting this value to false disables the app (takes the app offline).
hostingEnvironmentProfileoptionalidoptional - stringResource ID of the App Service Environment.
hostNamesDisabledoptional - boolean<code>true</code> to disable the public hostnames of the app; otherwise, <code>false</code>. If <code>true</code>, the app is only accessible via API management process.
hostNameSslStatesoptional arrayhostTypeoptional - stringIndicates whether the hostname is a standard or repository hostname.
nameoptional - stringHostname.
sslStateoptional - stringSSL type.
thumbprintoptional - stringSSL certificate thumbprint.
toUpdateoptional - booleanSet to <code>true</code> to update existing hostname.
virtualIPoptional - stringVirtual IP address assigned to the hostname if IP based SSL is enabled.
httpsOnlyoptional - booleanHttpsOnly: configures a web site to accept only https requests. Issues redirect for http requests
hyperVoptional - booleanHyper-V sandbox.
isXenonoptional - booleanObsolete: Hyper-V sandbox.
keyVaultReferenceIdentityoptional - stringIdentity to use for Key Vault Reference authentication.
redundancyModeoptional - stringSite redundancy mode.
reservedoptional - boolean<code>true</code> if reserved; otherwise, <code>false</code>.
scmSiteAlsoStoppedoptional - boolean<code>true</code> to stop SCM (KUDU) site when the app is stopped; otherwise, <code>false</code>. The default is <code>false</code>.
serverFarmIdoptional - stringResource ID of the associated App Service plan, formatted as: "/subscriptions/{subscriptionID}/resourceGroups/{groupName}/providers/Microsoft.Web/serverfarms/{appServicePlanName}".
siteConfigoptionalacrUseManagedIdentityCredsoptional - booleanFlag to use Managed Identity Creds for ACR pull
acrUserManagedIdentityIDoptional - stringIf using user managed identity, the user managed identity ClientId
alwaysOnoptional - boolean<code>true</code> if Always On is enabled; otherwise, <code>false</code>.
apiDefinitionoptionalurloptional - stringThe URL of the API definition.
apiManagementConfigoptionalidoptional - stringAPIM-Api Identifier.
appCommandLineoptional - stringApp command line to launch.
appSettingsoptional arraynameoptional - stringPair name.
valueoptional - stringPair value.
autoHealEnabledoptional - boolean<code>true</code> if Auto Heal is enabled; otherwise, <code>false</code>.
autoHealRulesoptionalactionsoptionalactionTypeoptional - stringPredefined action to be taken.
customActionoptionalexeoptional - stringExecutable to be run.
parametersoptional - stringParameters for the executable.
minProcessExecutionTimeoptional - stringMinimum time the process must execute before taking the action
triggersoptionalprivateBytesInKBoptional - integerA rule based on private bytes.
requestsoptionalcountoptional - integerRequest Count.
timeIntervaloptional - stringTime interval.
slowRequestsoptionalcountoptional - integerRequest Count.
pathoptional - stringRequest Path.
timeIntervaloptional - stringTime interval.
timeTakenoptional - stringTime taken.
slowRequestsWithPathoptional arraycountoptional - integerRequest Count.
pathoptional - stringRequest Path.
timeIntervaloptional - stringTime interval.
timeTakenoptional - stringTime taken.
statusCodesoptional arraycountoptional - integerRequest Count.
pathoptional - stringRequest Path
statusoptional - integerHTTP status code.
subStatusoptional - integerRequest Sub Status.
timeIntervaloptional - stringTime interval.
win32Statusoptional - integerWin32 error code.
statusCodesRangeoptional arraycountoptional - integerRequest Count.
pathoptional - stringstatusCodesoptional - stringHTTP status code.
timeIntervaloptional - stringTime interval.
autoSwapSlotNameoptional - stringAuto-swap slot name.
azureStorageAccountsoptional - undefinedList of Azure Storage Accounts.
connectionStringsoptional arrayconnectionStringoptional - stringConnection string value.
nameoptional - stringName of connection string.
typeoptional - stringType of database.
corsoptionalallowedOriginsoptional - arrayGets or sets the list of origins that should be allowed to make cross-origin calls (for example: http://example.com:12345). Use "*" to allow all.
supportCredentialsoptional - booleanGets or sets whether CORS requests with credentials are allowed. See https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS#Requests_with_credentials for more details.
defaultDocumentsoptional - arrayDefault documents.
detailedErrorLoggingEnabledoptional - boolean<code>true</code> if detailed error logging is enabled; otherwise, <code>false</code>.
documentRootoptional - stringDocument root.
experimentsoptionalrampUpRulesoptional arrayactionHostNameoptional - stringHostname of a slot to which the traffic will be redirected if decided to. E.g. myapp-stage.azurewebsites.net.
changeDecisionCallbackUrloptional - stringCustom 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/
changeIntervalInMinutesoptional - integerSpecifies interval in minutes to reevaluate ReroutePercentage.
changeStepoptional - numberIn auto ramp up scenario this is the step to add/remove from <code>ReroutePercentage</code> until it reaches \n<code>MinReroutePercentage</code> or <code>MaxReroutePercentage</code>. Site metrics are checked every N minutes specified in <code>ChangeIntervalInMinutes</code>.\nCustom decision algorithm can be provided in TiPCallback site extension which URL can be specified in <code>ChangeDecisionCallbackUrl</code>.
maxReroutePercentageoptional - numberSpecifies upper boundary below which ReroutePercentage will stay.
minReroutePercentageoptional - numberSpecifies lower boundary above which ReroutePercentage will stay.
nameoptional - stringName of the routing rule. The recommended name would be to point to the slot which will receive the traffic in the experiment.
reroutePercentageoptional - numberPercentage of the traffic which will be redirected to <code>ActionHostName</code>.
ftpsStateoptional - stringState of FTP / FTPS service.
functionAppScaleLimitoptional - integerMaximum number of workers that a site can scale out to. This setting only applies to the Consumption and Elastic Premium Plans
functionsRuntimeScaleMonitoringEnabledoptional - booleanGets or sets a value indicating whether functions runtime scale monitoring is enabled. When enabled, the ScaleController will not monitor event sources directly, but will instead call to the runtime to get scale status.
handlerMappingsoptional arrayargumentsoptional - stringCommand-line arguments to be passed to the script processor.
extensionoptional - stringRequests with this extension will be handled using the specified FastCGI application.
scriptProcessoroptional - stringThe absolute path to the FastCGI application.
healthCheckPathoptional - stringHealth check path
http20Enabledoptional - booleanHttp20Enabled: configures a web site to allow clients to connect over http2.0
httpLoggingEnabledoptional - boolean<code>true</code> if HTTP logging is enabled; otherwise, <code>false</code>.
ipSecurityRestrictionsoptional arrayactionoptional - stringAllow or Deny access for this IP range.
descriptionoptional - stringIP restriction rule description.
headersoptional - arrayIP restriction rule headers. X-Forwarded-Host (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-Host#Examples). The matching logic is ..
- If the property is null or empty (default), all hosts(or lack of) are allowed.
- A value is compared using ordinal-ignore-case (excluding port number).
- Subdomain wildcards are permitted but don't match the root domain. For example, *.contoso.com matches the subdomain foo.contoso.com but not the root domain contoso.com or multi-level foo.bar.contoso.com
- Unicode host names are allowed but are converted to Punycode for matching. X-Forwarded-For (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For#Examples). The matching logic is ..
- If the property is null or empty (default), any forwarded-for chains (or lack of) are allowed.
- If any address (excluding port number) in the chain (comma separated) matches the CIDR defined by the property. X-Azure-FDID and X-FD-HealthProbe. The matching logic is exact match.
ipAddressoptional - stringIP address the security restriction is valid for. It can be in form of pure ipv4 address (required SubnetMask property) or CIDR notation such as ipv4/mask (leading bit match). For CIDR, SubnetMask property must not be specified.
nameoptional - stringIP restriction rule name.
priorityoptional - integerPriority of IP restriction rule.
subnetMaskoptional - stringSubnet mask for the range of IP addresses the restriction is valid for.
subnetTrafficTagoptional - integer(internal) Subnet traffic tag
tagoptional - stringDefines what this IP filter will be used for. This is to support IP filtering on proxies.
vnetSubnetResourceIdoptional - stringVirtual network resource id
vnetTrafficTagoptional - integer(internal) Vnet traffic tag
javaContaineroptional - stringJava container.
javaContainerVersionoptional - stringJava container version.
javaVersionoptional - stringJava version.
keyVaultReferenceIdentityoptional - stringIdentity to use for Key Vault Reference authentication.
limitsoptionalmaxDiskSizeInMboptional - integerMaximum allowed disk size usage in MB.
maxMemoryInMboptional - integerMaximum allowed memory usage in MB.
maxPercentageCpuoptional - numberMaximum allowed CPU usage percentage.
linuxFxVersionoptional - stringLinux App Framework and version
loadBalancingoptional - stringSite load balancing.
localMySqlEnabledoptional - boolean<code>true</code> to enable local MySQL; otherwise, <code>false</code>.
logsDirectorySizeLimitoptional - integerHTTP logs directory size limit.
managedPipelineModeoptional - stringManaged pipeline mode.
managedServiceIdentityIdoptional - integerManaged Service Identity Id
minimumElasticInstanceCountoptional - integerNumber of minimum instance count for a site This setting only applies to the Elastic Plans
minTlsVersionoptional - stringMinTlsVersion: configures the minimum version of TLS required for SSL requests.
netFrameworkVersionoptional - string.NET Framework version.
nodeVersionoptional - stringVersion of Node.js.
numberOfWorkersoptional - integerNumber of workers.
phpVersionoptional - stringVersion of PHP.
powerShellVersionoptional - stringVersion of PowerShell.
preWarmedInstanceCountoptional - integerNumber of preWarmed instances. This setting only applies to the Consumption and Elastic Plans
publicNetworkAccessoptional - stringProperty to allow or block all public traffic.
publishingUsernameoptional - stringPublishing user name.
pushoptionalkindoptional - stringKind of resource.
propertiesoptionaldynamicTagsJsonoptional - stringGets or sets a JSON string containing a list of dynamic tags that will be evaluated from user claims in the push registration endpoint.
isPushEnabledrequired - booleanGets or sets a flag indicating whether the Push endpoint is enabled.
tagsRequiringAuthoptional - stringGets 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.
tagWhitelistJsonoptional - stringGets or sets a JSON string containing a list of tags that are whitelisted for use by the push registration endpoint.
pythonVersionoptional - stringVersion of Python.
remoteDebuggingEnabledoptional - boolean<code>true</code> if remote debugging is enabled; otherwise, <code>false</code>.
remoteDebuggingVersionoptional - stringRemote debugging version.
requestTracingEnabledoptional - boolean<code>true</code> if request tracing is enabled; otherwise, <code>false</code>.
requestTracingExpirationTimeoptional - stringRequest tracing expiration time.
scmIpSecurityRestrictionsoptional arrayactionoptional - stringAllow or Deny access for this IP range.
descriptionoptional - stringIP restriction rule description.
headersoptional - arrayIP restriction rule headers. X-Forwarded-Host (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-Host#Examples). The matching logic is ..
- If the property is null or empty (default), all hosts(or lack of) are allowed.
- A value is compared using ordinal-ignore-case (excluding port number).
- Subdomain wildcards are permitted but don't match the root domain. For example, *.contoso.com matches the subdomain foo.contoso.com but not the root domain contoso.com or multi-level foo.bar.contoso.com
- Unicode host names are allowed but are converted to Punycode for matching. X-Forwarded-For (https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For#Examples). The matching logic is ..
- If the property is null or empty (default), any forwarded-for chains (or lack of) are allowed.
- If any address (excluding port number) in the chain (comma separated) matches the CIDR defined by the property. X-Azure-FDID and X-FD-HealthProbe. The matching logic is exact match.
ipAddressoptional - stringIP address the security restriction is valid for. It can be in form of pure ipv4 address (required SubnetMask property) or CIDR notation such as ipv4/mask (leading bit match). For CIDR, SubnetMask property must not be specified.
nameoptional - stringIP restriction rule name.
priorityoptional - integerPriority of IP restriction rule.
subnetMaskoptional - stringSubnet mask for the range of IP addresses the restriction is valid for.
subnetTrafficTagoptional - integer(internal) Subnet traffic tag
tagoptional - stringDefines what this IP filter will be used for. This is to support IP filtering on proxies.
vnetSubnetResourceIdoptional - stringVirtual network resource id
vnetTrafficTagoptional - integer(internal) Vnet traffic tag
scmIpSecurityRestrictionsUseMainoptional - booleanIP security restrictions for scm to use main.
scmMinTlsVersionoptional - stringScmMinTlsVersion: configures the minimum version of TLS required for SSL requests for SCM site.
scmTypeoptional - stringSCM type.
tracingOptionsoptional - stringTracing options.
use32BitWorkerProcessoptional - boolean<code>true</code> to use 32-bit worker process; otherwise, <code>false</code>.
virtualApplicationsoptional arrayphysicalPathoptional - stringPhysical path.
preloadEnabledoptional - boolean<code>true</code> if preloading is enabled; otherwise, <code>false</code>.
virtualDirectoriesoptional arrayphysicalPathoptional - stringPhysical path.
virtualPathoptional - stringPath to virtual application.
virtualPathoptional - stringVirtual path.
vnetNameoptional - stringVirtual Network name.
vnetPrivatePortsCountoptional - integerThe number of private ports assigned to this app. These will be assigned dynamically on runtime.
vnetRouteAllEnabledoptional - booleanVirtual Network Route All enabled. This causes all outbound traffic to have Virtual Network Security Groups and User Defined Routes applied.
websiteTimeZoneoptional - stringSets the time zone a site uses for generating timestamps. Compatible with Linux and Windows App Service. Setting the WEBSITE_TIME_ZONE app setting takes precedence over this config. For Linux, expects tz database values https://www.iana.org/time-zones (for a quick reference see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones). For Windows, expects one of the time zones listed under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Time Zones
webSocketsEnabledoptional - boolean<code>true</code> if WebSocket is enabled; otherwise, <code>false</code>.
windowsFxVersionoptional - stringXenon App Framework and version
xManagedServiceIdentityIdoptional - integerExplicit Managed Service Identity Id
storageAccountRequiredoptional - booleanChecks if Customer provided storage account is required
virtualNetworkSubnetIdoptional - stringAzure Resource Manager ID of the Virtual network and subnet to be joined by Regional VNET Integration. This must be of the form /subscriptions/{subscriptionName}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{vnetName}/subnets/{subnetName}
tagsoptional - stringResource tags.
typerequired - string