Azure App Service
The Azure plugin supports deploying and managing Azure App Service resources including Web Apps, Static Web Apps, and associated configurations such as deployment slots, logging, and site extensions.
Prerequisites
Before you begin, ensure you have:
- Set up an Azure Cloud connection.
- A Resource Group (
azure.ResourceGroup) provisioned in your environment CI.
Create an App Service Plan
An App Service Plan (azure.AppServicePlan) defines the compute resources and pricing tier for Web Apps and Function Apps hosted within it.
-
In the side navigation bar, click Explorer.
-
Under Applications, expand your application and provisioning package.
-
Click
, then select New > azure > AppServicePlanSpec.
-
Specify the following properties:
Property Required Description Service Plan Name No Name of the App Service Plan. Defaults to the CI name if not specified. Location Yes Azure region where the plan is hosted (for example, westus).SKU Name No Pricing tier name. Default: S1.SKU Tier No Pricing tier level. Default: Basic.SKU Size No Instance size. Default: 1.SKU Family No Pricing family. Default: S.SKU Capacity No Number of worker instances. Default: 0.OS Type No Windows(default) orLinux. -
Click Save and close.
Deploy a Web App
An azure.WebApp creates an Azure Web App in a Resource Group, bound to an App Service Plan. Use this for code-based deployments without an artifact at provision time.
-
Under your provisioning package, click
, then select New > azure > WebAppSpec.
-
Specify the following properties:
Property Required Description App Name No Name of the Web App. Defaults to the CI name. Service Plan Name Yes Name of the App Service Plan to use. Location Yes Azure region (for example, westus).Linux Fx Version No Linux framework and version (for example, `TOMCAT Windows Fx Version No Windows framework and version. Startup Command No Optional startup command run during container startup. App Settings No Key-value pairs for application settings. App Tags No Tags to associate with the Web App. SQL Database Connection Strings No Connection strings for Azure SQL Database. SQL Server Connection Strings No Connection strings for SQL Server. Custom Connection Strings No Custom connection string key-value pairs. Add System Assigned Identity No If true, adds a system-assigned managed identity to the Web App.User Assigned Identities No List of user-assigned managed identity resource IDs. To specify an identity from a different resource group, provide its full resource ID. -
Click Save and close and deploy.
Deploy Code to a Web App
Use azure.WebAppCode to deploy a file artifact (WAR, JAR, ZIP, and so on) to an existing Web App.
-
Under your application package, click
, then select New > azure > WebAppCodeSpec.
-
Specify the following properties:
Property Required Description Web App Name Yes Name of the target Web App. Artifact Type No Type of artifact: war,jar,ear,lib,startup,static, orzip.Clean Target Space No If true, cleans the deployment space before deploying. Caution: this removes existing deployed files. Default:false.Target Path No Absolute deployment path on the Web App. Deployment Slot No Deployment slot to target (if using slots). -
Attach the artifact file to the CI.
-
Click Save and close and deploy.
Deploy a Web App as a Container
Use azure.WebAppContainer to deploy a containerized Web App from a Docker registry or Azure Container Registry (ACR).
-
Under your provisioning package, click
, then select New > azure > WebAppContainerSpec.
-
Specify the following properties:
Property Required Description App Name No Name of the Web App. Defaults to the CI name. Service Plan Name Yes Name of the App Service Plan to use. Location Yes Azure region. OS Type Yes Linux(default) orWindows.Image Name Yes Docker image name and tag (for example, myregistry.azurecr.io/myapp:latest).Registry URL Yes ACR or Docker registry URL. Registry Username No Registry username for authentication. Registry Password No Registry password. Startup Command No Optional startup command. Expose Port No Port to expose. Default: 0.App Settings No Application settings key-value pairs. SQL Database Connection Strings No Connection strings for Azure SQL Database. SQL Server Connection Strings No SQL Server connection strings. Custom Connection Strings No Custom connection strings. App Tags No Tags for the Web App. Add System Assigned Identity No Adds a system-assigned managed identity. User Assigned Identities No List of user-assigned managed identity resource IDs. -
Click Save and close and deploy.
Deploy a Static Web App
Use azure.StaticWebApp to create an Azure Static Web App with optional GitHub repository integration for continuous deployment.
-
Under your provisioning package, click
, then select New > azure > StaticWebAppSpec.
-
Specify the following properties:
Property Required Description App Name No Name of the Static Web App. Defaults to the CI name. Location Yes Azure region. Hosting Plan Yes Free(default) orStandard.Repository URL No GitHub repository URL for the static site. Branch No Target branch in the repository. Repository Token No GitHub personal access token to set up the GitHub Actions workflow and API secrets. App Location No Path to the app source code in the repository. API Location No Path to the API source code in the repository. App Artifact Location No Build output path for app artifacts. App Tags No Tags to associate with the Static Web App. App Settings No Application settings key-value pairs. Add System Assigned Identity No Adds a system-assigned managed identity. User Assigned Identities No List of user-assigned managed identity resource IDs. -
Click Save and close and deploy.
Create a Web App Deployment Slot
Use azure.WebAppSlot to create a deployment slot on an existing Web App. Deployment slots allow staged deployments and slot-swap workflows.
-
Under your provisioning package, click
, then select New > azure > WebAppSlotSpec.
-
Specify the following properties:
Property Required Description Web App Name Yes Name of the Web App to add the slot to. Slot Name Yes Name of the new deployment slot. Clone Settings From Yes Choose Clone configuration from WebApp,Clone configuration from Deployment slot, orDo not clone settings.Clone From Web App No Name of the Web App whose configuration to clone. Required if cloning from a Web App. Clone From Deployment Slot No Name of the deployment slot to clone configuration from. Required if cloning from a slot. -
Click Save and close and deploy.
Configure Web App Logging
Use azure.WebAppLogging to configure diagnostic logging settings for a Web App.
-
Under your provisioning package, click
, then select New > azure > WebAppLoggingSpec.
-
Specify the following properties:
Property Description Web App Name Name of the Web App to configure logging for. Application Logging (FileSystem) OnorOff. Enables file system application logging.Log Level (FileSystem) Error,Warning,Information, orVerbose. Required when file system logging is enabled.Application Logging (Blob) OnorOff. Enables blob storage application logging.Log Level (Blob) Log level for blob logging. Required when blob logging is enabled. Storage Account URL (Blob) SAS URL of an Azure blob container for application logs. Requires read/write/list/delete permissions. Retention Period (Blob) Days to retain blob logs. 0means no retention.Web Server Logging Off,FileSystem, orStorage.Quota (MB) Max size in MB for HTTP log files when using FileSystem (25–100 MB, default: 35). Old log files are removed when the quota is reached. Retention Period (FileSystem) Days to retain HTTP log files. 0means no retention.Storage Account URL (Storage) SAS URL for web server log storage. Retention Period (Storage) Days to retain web server logs stored in blob storage. Detailed Error Messages OnorOff.Failed Requests Tracing OnorOff. -
Click Save and close and deploy.
Add a Web App Extension
Use azure.WebAppExtension to install a site extension on a Web App.
-
Under your provisioning package, click
, then select New > azure > WebAppExtensionSpec.
-
Specify the following properties:
Property Required Description Web App Name Yes Name of the Web App to add the extension to. Site Extension ID Yes Identifier of the site extension to install (for example, Raygun.AzureAppService.Extensionfor .Net Raygun APM). -
Click Save and close and deploy.