Documentation menu

resources

Web App

Overview

A Web App must reference a Dedicated App Service plan with type: "web_app". The plan operating system must match the Web App’s os property.

{
	"resources": [
		{
			"app_service_plan": {
				"name": "plan-web-{env}",
				"kind": "P0v3",
				"os": "linux",
				"type": "web_app",
				"instance_count": 1
			}
		},
		{
			"web_app": {
				"name": "web-app-{env}",
				"@plan_name": "plan-web-{env}",
				"os": "linux",
				"runtime": "node20",
				"https_only": true,
				"app_settings": [
					{
						"type": "String",
						"name": "MY_APP_SETTING",
						"value": "MY_APP_SETTING_VALUE",
						"slot": false
					}
				]
			}
		}
	]
}

Consumption, FlexConsumption, and EP1–EP3 are Function App hosting SKUs and cannot host a Hulk Web App.

Redeployment behavior

Hulk emits a stable Web App definition for repeated hulk transpile and az deployment group create runs. The optional https_only and client_affinity_enabled properties are omitted from generated Bicep when they aren’t declared. This preserves the existing Azure value for users upgrading from earlier Hulk versions. Set https_only: true explicitly for new apps.

The app_settings array is the Hulk-managed configuration. Declare settings in source control instead of depending on undeclared values added manually in Azure. Reserved platform settings generated by Hulk cannot be overridden.

Web App definition

Key Type Description
name (required) string Web App name.
@plan_name (required) App Service plan reference Dedicated plan defined in the same Hulk configuration with type: "web_app".
os (required) windows or linux Must match the referenced plan.
runtime (required) Runtime Language stack or Linux container configuration.
@application_insights_name Application Insights reference Adds Application Insights configuration.
diagnostic_settings diagnostic settings Sends supported App Service logs and metrics to configured destinations.
app_settings array of AppSetting Hulk-managed application settings.
run_from_package boolean Enables run-from-package. Defaults to true.
is_64bit boolean Enables a 64-bit worker process. Defaults to false where applicable.
https_only boolean Require HTTPS. Recommended as true for new apps. If omitted, the existing Azure value is unchanged.
client_affinity_enabled boolean Enable client-affinity cookies. If omitted, the existing Azure value is unchanged.
custom_domains array of CustomDomain Custom domains.
cors CORS CORS configuration.
vnet_config VirtualNetwork Virtual network integration.
slot_settings SlotSettings Deployment slot configuration.
location string Defaults to the resource group location.
external boolean Reference an existing Web App. Defaults to false.
resource_group_name string Resource group for an external app; otherwise defaults to the deployment resource group.
tags object Additional resource tags.

Runtime

The os field selects which runtime values are accepted.

Linux runtimes

Value Stack
node18, node20 Node.js
dotnetcore6, dotnetcore7, dotnetcore8 .NET
python3_8, python3_9, python3_10, python3_11, python3_12 Python
php8_0, php8_1, php8_2, php8_3 PHP
java17, java21 Java
docker Private or public container image; use the object form below.
{
	"os": "linux",
	"runtime": {
		"docker": {
			"domain": "registry.azurecr.io",
			"repository": "apps",
			"image": "api",
			"tag": "1.0.0"
		}
	}
}

Windows runtimes

Value Stack
dotnet6, dotnet7, dotnet8 .NET
node18, node20 Node.js

AppSetting

Key Description
type (required) String or KeyVault.
name (required) Application setting name.
value (required for String) Literal string value.
@key_vault_name (for KeyVault) Referenced Key Vault.
secret_name (for KeyVault) Secret name in the Key Vault.
slot Marks the setting as slot-sticky. Defaults to false.

CustomDomain

Key Description
custom_domain Fully qualified custom domain.
@dns_zone_name Azure DNS zone reference.
dns_zone_resource_group Resource group containing the DNS zone.

VirtualNetwork

Key Type Description
@vnet_name string Virtual network reference.
@subnet_name string Subnet reference.

SlotSettings

Key Type Description
enabled (required) boolean Enables the deployment slot.
name string Slot name. Defaults to preprod.

CORS

Key Type Description
allowed_origins (required) string[] Allowed origins.
support_credentials (required) boolean Whether credentialed requests are allowed.