AzureRmWebAppDeployment@4- Azure App Service v4-taak implementeren

Gebruik deze taak om te implementeren om een web-, mobiele of API-app te Azure App Service met behulp van Docker, Java, .NET, .NET Core, Node.js, PHP, Python of Ruby.

Notitie

Gebruik AzureFunctionApp@1 om Azure Functions apps te implementeren.

Werk Azure-app Services in Windows, Web App op Linux bij met ingebouwde installatiekopieën of Docker-containers, ASP.NET, .NET Core, PHP, Python of Node.js gebaseerde webtoepassingen, functie-apps op Windows of Linux met Docker Containers, Mobile Apps, API-toepassingen en webtaken met behulp van Web Deploy/Kudu REST API's.

Syntax

# Azure App Service deploy v4
# Deploy to Azure App Service a web, mobile, or API app using Docker, Java, .NET, .NET Core, Node.js, PHP, Python, or Ruby.
- task: AzureRmWebAppDeployment@4
  inputs:
    ConnectionType: 'AzureRM' # 'AzureRM' | 'PublishProfile'. Required. Connection type. Default: AzureRM.
    azureSubscription: # string. Alias: ConnectedServiceName. Required when ConnectionType = AzureRM. Azure subscription. 
    #PublishProfilePath: '$(System.DefaultWorkingDirectory)/**/*.pubxml' # string. Required when ConnectionType = PublishProfile. Publish profile path. Default: $(System.DefaultWorkingDirectory)/**/*.pubxml.
    #PublishProfilePassword: # string. Required when ConnectionType = PublishProfile. Publish profile password. 
    appType: 'webApp' # 'webApp' | 'webAppLinux' | 'webAppContainer' | 'webAppHyperVContainer' | 'functionApp' | 'functionAppLinux' | 'functionAppContainer' | 'apiApp' | 'mobileApp'. Alias: WebAppKind. Required when ConnectionType = AzureRM. App Service type. Default: webApp.
    WebAppName: # string. Required when ConnectionType = AzureRM. App Service name. 
    #deployToSlotOrASE: false # boolean. Alias: DeployToSlotOrASEFlag. Optional. Use when ConnectionType = AzureRM && WebAppKind != "". Deploy to Slot or App Service Environment. Default: false.
    #ResourceGroupName: # string. Required when DeployToSlotOrASEFlag = true. Resource group. 
    #SlotName: 'production' # string. Required when DeployToSlotOrASEFlag = true. Slot. Default: production.
    #DockerNamespace: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = webAppHyperVContainer. Registry or Namespace. 
    #DockerRepository: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = webAppHyperVContainer. Image. 
    #DockerImageTag: # string. Optional. Use when WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = webAppHyperVContainer. Tag. 
    #VirtualApplication: # string. Optional. Use when WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != functionApp && webAppKind != functionAppLinux && WebAppKind != "". Virtual application. 
    #packageForLinux: '$(System.DefaultWorkingDirectory)/**/*.zip' # string. Alias: Package. Required when ConnectionType = PublishProfile || WebAppKind = webApp || WebAppKind = apiApp || WebAppKind = functionApp || WebAppKind = mobileApp || WebAppKind = webAppLinux || webAppKind = functionAppLinux. Package or folder. Default: $(System.DefaultWorkingDirectory)/**/*.zip.
    #RuntimeStack: # string. Optional. Use when WebAppKind = webAppLinux. Runtime Stack. 
    #RuntimeStackFunction: # 'DOTNET|2.2' | 'DOTNET|3.1' | 'JAVA|8' | 'JAVA|11' | 'NODE|8' | 'NODE|10' | 'NODE|12' | 'NODE|14' | 'PYTHON|3.6' | 'PYTHON|3.7' | 'PYTHON|3.8'. Optional. Use when WebAppKind = functionAppLinux. Runtime Stack. 
    #StartupCommand: # string. Optional. Use when WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux || WebAppKind = webAppHyperVContainer. Startup command. 
  # Post Deployment Action
    #ScriptType: # 'Inline Script' | 'File Path'. Optional. Use when ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer. Deployment script type. 
    #InlineScript: ':: You can provide your deployment commands here. One command per line.' # string. Required when ScriptType == Inline Script && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer. Inline Script. Default: :: You can provide your deployment commands here. One command per line..
    #ScriptPath: # string. Required when ScriptType == File Path && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer. Deployment script path. 
  # File Transforms & Variable Substitution Options
    #WebConfigParameters: # string. Optional. Use when WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Generate web.config parameters for Python, Node.js, Go and Java apps. 
    #enableXmlTransform: false # boolean. Alias: XmlTransformation. Optional. Use when WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML transformation. Default: false.
    #enableXmlVariableSubstitution: false # boolean. Alias: XmlVariableSubstitution. Optional. Use when WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML variable substitution. Default: false.
    #JSONFiles: # string. Optional. Use when WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. JSON variable substitution. 
  # Application and Configuration Settings
    #AppSettings: # string. Optional. Use when ConnectionType = AzureRM. App settings. 
    #ConfigurationSettings: # string. Optional. Use when ConnectionType = AzureRM. Configuration settings. 
  # Additional Deployment Options
    #enableCustomDeployment: false # boolean. Alias: UseWebDeploy. Optional. Use when ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Select deployment method. Default: false.
    #DeploymentType: 'webDeploy' # 'webDeploy' | 'zipDeploy' | 'runFromZip'. Required when UseWebDeploy == true && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Deployment method. Default: webDeploy.
    #TakeAppOfflineFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType != runFromZip && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Take App Offline. Default: true.
    #SetParametersFile: # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. SetParameters file. 
    #RemoveAdditionalFilesFlag: false # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Remove additional files at destination. Default: false.
    #ExcludeFilesFromAppDataFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Exclude files from the App_Data folder. Default: true.
    #AdditionalArguments: '-retryAttempts:6 -retryInterval:10000' # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Additional arguments. Default: -retryAttempts:6 -retryInterval:10000.
    #RenameFilesFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Rename locked files. Default: true.
# Azure App Service deploy v4
# Deploy to Azure App Service a web, mobile, or API app using Docker, Java, .NET, .NET Core, Node.js, PHP, Python, or Ruby.
- task: AzureRmWebAppDeployment@4
  inputs:
    ConnectionType: 'AzureRM' # 'AzureRM' | 'PublishProfile'. Required. Connection type. Default: AzureRM.
    azureSubscription: # string. Alias: ConnectedServiceName. Required when ConnectionType = AzureRM. Azure subscription. 
    #PublishProfilePath: '$(System.DefaultWorkingDirectory)/**/*.pubxml' # string. Required when ConnectionType = PublishProfile. Publish profile path. Default: $(System.DefaultWorkingDirectory)/**/*.pubxml.
    #PublishProfilePassword: # string. Required when ConnectionType = PublishProfile. Publish profile password. 
    appType: 'webApp' # 'webApp' | 'webAppLinux' | 'webAppContainer' | 'webAppHyperVContainer' | 'functionApp' | 'functionAppLinux' | 'functionAppContainer' | 'apiApp' | 'mobileApp'. Alias: WebAppKind. Required when ConnectionType = AzureRM. App Service type. Default: webApp.
    WebAppName: # string. Required when ConnectionType = AzureRM. App Service name. 
    #deployToSlotOrASE: false # boolean. Alias: DeployToSlotOrASEFlag. Optional. Use when ConnectionType = AzureRM && WebAppKind != "". Deploy to Slot or App Service Environment. Default: false.
    #ResourceGroupName: # string. Required when DeployToSlotOrASEFlag = true. Resource group. 
    #SlotName: 'production' # string. Required when DeployToSlotOrASEFlag = true. Slot. Default: production.
    #DockerNamespace: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppkind = webAppHyperVContainer. Registry or Namespace. 
    #DockerRepository: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppkind = webAppHyperVContainer. Image. 
    #DockerImageTag: # string. Optional. Use when WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppkind = webAppHyperVContainer. Tag. 
    #VirtualApplication: # string. Optional. Use when WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != functionApp && webAppKind != functionAppLinux && WebAppKind != "". Virtual application. 
    #packageForLinux: '$(System.DefaultWorkingDirectory)/**/*.zip' # string. Alias: Package. Required when ConnectionType = PublishProfile || WebAppKind = webApp || WebAppKind = apiApp || WebAppKind = functionApp || WebAppKind = mobileApp || WebAppKind = webAppLinux || webAppKind = functionAppLinux. Package or folder. Default: $(System.DefaultWorkingDirectory)/**/*.zip.
    #RuntimeStack: # string. Optional. Use when WebAppKind = webAppLinux. Runtime Stack. 
    #RuntimeStackFunction: # 'DOTNET|2.2' | 'DOTNET|3.1' | 'JAVA|8' | 'JAVA|11' | 'NODE|8' | 'NODE|10' | 'NODE|12' | 'NODE|14' | 'PYTHON|3.6' | 'PYTHON|3.7' | 'PYTHON|3.8'. Optional. Use when WebAppKind = functionAppLinux. Runtime Stack. 
    #StartupCommand: # string. Optional. Use when WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux || WebAppkind = webAppHyperVContainer. Startup command. 
  # Post Deployment Action
    #ScriptType: # 'Inline Script' | 'File Path'. Optional. Use when ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script type. 
    #InlineScript: ':: You can provide your deployment commands here. One command per line.' # string. Required when ScriptType == Inline Script && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Inline Script. Default: :: You can provide your deployment commands here. One command per line..
    #ScriptPath: # string. Required when ScriptType == File Path && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script path. 
  # File Transforms & Variable Substitution Options
    #WebConfigParameters: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Generate web.config parameters for Python, Node.js, Go and Java apps. 
    #enableXmlTransform: false # boolean. Alias: XmlTransformation. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML transformation. Default: false.
    #enableXmlVariableSubstitution: false # boolean. Alias: XmlVariableSubstitution. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML variable substitution. Default: false.
    #JSONFiles: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. JSON variable substitution. 
  # Application and Configuration Settings
    #AppSettings: # string. Optional. Use when ConnectionType = AzureRM. App settings. 
    #ConfigurationSettings: # string. Optional. Use when ConnectionType = AzureRM. Configuration settings. 
  # Additional Deployment Options
    #enableCustomDeployment: false # boolean. Alias: UseWebDeploy. Optional. Use when ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Select deployment method. Default: false.
    #DeploymentType: 'webDeploy' # 'webDeploy' | 'zipDeploy' | 'runFromZip'. Required when UseWebDeploy == true && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Deployment method. Default: webDeploy.
    #TakeAppOfflineFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType != runFromZip && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Take App Offline. Default: true.
    #SetParametersFile: # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. SetParameters file. 
    #RemoveAdditionalFilesFlag: false # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Remove additional files at destination. Default: false.
    #ExcludeFilesFromAppDataFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Exclude files from the App_Data folder. Default: true.
    #AdditionalArguments: '-retryAttempts:6 -retryInterval:10000' # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Additional arguments. Default: -retryAttempts:6 -retryInterval:10000.
    #RenameFilesFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Rename locked files. Default: true.
# Azure App Service deploy v4
# Deploy to Azure App Service a web, mobile, or API app using Docker, Java, .NET, .NET Core, Node.js, PHP, Python, or Ruby.
- task: AzureRmWebAppDeployment@4
  inputs:
    ConnectionType: 'AzureRM' # 'AzureRM' | 'PublishProfile'. Required. Connection type. Default: AzureRM.
    azureSubscription: # string. Alias: ConnectedServiceName. Required when ConnectionType = AzureRM. Azure subscription. 
    #PublishProfilePath: '$(System.DefaultWorkingDirectory)/**/*.pubxml' # string. Required when ConnectionType = PublishProfile. Publish profile path. Default: $(System.DefaultWorkingDirectory)/**/*.pubxml.
    #PublishProfilePassword: # string. Required when ConnectionType = PublishProfile. Publish profile password. 
    appType: 'webApp' # 'webApp' | 'webAppLinux' | 'webAppContainer' | 'functionApp' | 'functionAppLinux' | 'functionAppContainer' | 'apiApp' | 'mobileApp'. Alias: WebAppKind. Required when ConnectionType = AzureRM. App Service type. Default: webApp.
    WebAppName: # string. Required when ConnectionType = AzureRM. App Service name. 
    #deployToSlotOrASE: false # boolean. Alias: DeployToSlotOrASEFlag. Optional. Use when ConnectionType = AzureRM && WebAppKind != "". Deploy to Slot or App Service Environment. Default: false.
    #ResourceGroupName: # string. Required when DeployToSlotOrASEFlag = true. Resource group. 
    #SlotName: 'production' # string. Required when DeployToSlotOrASEFlag = true. Slot. Default: production.
    #DockerNamespace: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Registry or Namespace. 
    #DockerRepository: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Image. 
    #DockerImageTag: # string. Optional. Use when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Tag. 
    #VirtualApplication: # string. Optional. Use when WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != functionApp && webAppKind != functionAppLinux && WebAppKind != "". Virtual application. 
    #packageForLinux: '$(System.DefaultWorkingDirectory)/**/*.zip' # string. Alias: Package. Required when ConnectionType = PublishProfile || WebAppKind = webApp || WebAppKind = apiApp || WebAppKind = functionApp || WebAppKind = mobileApp || WebAppKind = webAppLinux || webAppKind = functionAppLinux. Package or folder. Default: $(System.DefaultWorkingDirectory)/**/*.zip.
    #RuntimeStack: # string. Optional. Use when WebAppKind = webAppLinux. Runtime Stack. 
    #RuntimeStackFunction: # 'DOTNET|2.2' | 'DOTNET|3.1' | 'JAVA|8' | 'JAVA|11' | 'NODE|8' | 'NODE|10' | 'NODE|12' | 'NODE|14' | 'PYTHON|3.6' | 'PYTHON|3.7' | 'PYTHON|3.8'. Optional. Use when WebAppKind = functionAppLinux. Runtime Stack. 
    #StartupCommand: # string. Optional. Use when WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux. Startup command. 
  # Post Deployment Action
    #ScriptType: # 'Inline Script' | 'File Path'. Optional. Use when ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script type. 
    #InlineScript: ':: You can provide your deployment commands here. One command per line.' # string. Required when ScriptType == Inline Script && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Inline Script. Default: :: You can provide your deployment commands here. One command per line..
    #ScriptPath: # string. Required when ScriptType == File Path && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script path. 
  # File Transforms & Variable Substitution Options
    #WebConfigParameters: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Generate web.config parameters for Python, Node.js, Go and Java apps. 
    #enableXmlTransform: false # boolean. Alias: XmlTransformation. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML transformation. Default: false.
    #enableXmlVariableSubstitution: false # boolean. Alias: XmlVariableSubstitution. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML variable substitution. Default: false.
    #JSONFiles: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. JSON variable substitution. 
  # Application and Configuration Settings
    #AppSettings: # string. Optional. Use when ConnectionType = AzureRM. App settings. 
    #ConfigurationSettings: # string. Optional. Use when ConnectionType = AzureRM. Configuration settings. 
  # Additional Deployment Options
    #enableCustomDeployment: false # boolean. Alias: UseWebDeploy. Optional. Use when ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Select deployment method. Default: false.
    #DeploymentType: 'webDeploy' # 'webDeploy' | 'zipDeploy' | 'runFromZip'. Required when UseWebDeploy == true && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Deployment method. Default: webDeploy.
    #TakeAppOfflineFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType != runFromZip && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Take App Offline. Default: true.
    #SetParametersFile: # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. SetParameters file. 
    #RemoveAdditionalFilesFlag: false # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Remove additional files at destination. Default: false.
    #ExcludeFilesFromAppDataFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Exclude files from the App_Data folder. Default: true.
    #AdditionalArguments: '-retryAttempts:6 -retryInterval:10000' # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Additional arguments. Default: -retryAttempts:6 -retryInterval:10000.
    #RenameFilesFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Rename locked files. Default: true.
# Azure App Service deploy v4
# Deploy to Azure App Service a web, mobile, or API app using Docker, Java, .NET, .NET Core, Node.js, PHP, Python, or Ruby.
- task: AzureRmWebAppDeployment@4
  inputs:
    ConnectionType: 'AzureRM' # 'AzureRM' | 'PublishProfile'. Required. Connection type. Default: AzureRM.
    azureSubscription: # string. Alias: ConnectedServiceName. Required when ConnectionType = AzureRM. Azure subscription. 
    #PublishProfilePath: '$(System.DefaultWorkingDirectory)/**/*.pubxml' # string. Required when ConnectionType = PublishProfile. Publish profile path. Default: $(System.DefaultWorkingDirectory)/**/*.pubxml.
    #PublishProfilePassword: # string. Required when ConnectionType = PublishProfile. Publish profile password. 
    appType: 'webApp' # 'webApp' | 'webAppLinux' | 'webAppContainer' | 'functionApp' | 'functionAppLinux' | 'functionAppContainer' | 'apiApp' | 'mobileApp'. Alias: WebAppKind. Required when ConnectionType = AzureRM. App Service type. Default: webApp.
    WebAppName: # string. Required when ConnectionType = AzureRM. App Service name. 
    #deployToSlotOrASE: false # boolean. Alias: DeployToSlotOrASEFlag. Optional. Use when ConnectionType = AzureRM && WebAppKind != "". Deploy to Slot or App Service Environment. Default: false.
    #ResourceGroupName: # string. Required when DeployToSlotOrASEFlag = true. Resource group. 
    #SlotName: 'production' # string. Required when DeployToSlotOrASEFlag = true. Slot. Default: production.
    #DockerNamespace: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Registry or Namespace. 
    #DockerRepository: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Image. 
    #DockerImageTag: # string. Optional. Use when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Tag. 
    #VirtualApplication: # string. Optional. Use when WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != functionApp && webAppKind != functionAppLinux && WebAppKind != "". Virtual application. 
    #packageForLinux: '$(System.DefaultWorkingDirectory)/**/*.zip' # string. Alias: Package. Required when ConnectionType = PublishProfile || WebAppKind = webApp || WebAppKind = apiApp || WebAppKind = functionApp || WebAppKind = mobileApp || WebAppKind = webAppLinux || webAppKind = functionAppLinux. Package or folder. Default: $(System.DefaultWorkingDirectory)/**/*.zip.
    #RuntimeStack: # string. Optional. Use when WebAppKind = webAppLinux. Runtime Stack. 
    #RuntimeStackFunction: # 'DOCKER|microsoft/azure-functions-dotnet-core2.0:2.0' | 'DOCKER|microsoft/azure-functions-node8:2.0'. Optional. Use when WebAppKind = functionAppLinux. Runtime Stack. 
    #StartupCommand: # string. Optional. Use when WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux. Startup command. 
  # Post Deployment Action
    #ScriptType: # 'Inline Script' | 'File Path'. Optional. Use when ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script type. 
    #InlineScript: ':: You can provide your deployment commands here. One command per line.' # string. Required when ScriptType == Inline Script && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Inline Script. Default: :: You can provide your deployment commands here. One command per line..
    #ScriptPath: # string. Required when ScriptType == File Path && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script path. 
  # File Transforms & Variable Substitution Options
    #WebConfigParameters: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Generate web.config parameters for Python, Node.js, Go and Java apps. 
    #enableXmlTransform: false # boolean. Alias: XmlTransformation. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML transformation. Default: false.
    #enableXmlVariableSubstitution: false # boolean. Alias: XmlVariableSubstitution. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML variable substitution. Default: false.
    #JSONFiles: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. JSON variable substitution. 
  # Application and Configuration Settings
    #AppSettings: # string. Optional. Use when ConnectionType = AzureRM. App settings. 
    #ConfigurationSettings: # string. Optional. Use when ConnectionType = AzureRM. Configuration settings. 
  # Additional Deployment Options
    #enableCustomDeployment: false # boolean. Alias: UseWebDeploy. Optional. Use when ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Select deployment method. Default: false.
    #DeploymentType: 'webDeploy' # 'webDeploy' | 'zipDeploy' | 'runFromZip'. Required when UseWebDeploy == true && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Deployment method. Default: webDeploy.
    #TakeAppOfflineFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType != runFromZip && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Take App Offline. Default: true.
    #SetParametersFile: # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. SetParameters file. 
    #RemoveAdditionalFilesFlag: false # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Remove additional files at destination. Default: false.
    #ExcludeFilesFromAppDataFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Exclude files from the App_Data folder. Default: true.
    #AdditionalArguments: '-retryAttempts:6 -retryInterval:10000' # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Additional arguments. Default: -retryAttempts:6 -retryInterval:10000.
    #RenameFilesFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Rename locked files. Default: true.
# Azure App Service Deploy v4
# Update Azure App Services on Windows, Web App on Linux with built-in images or Docker containers, ASP.NET, .NET Core, PHP, Python or Node.js based Web applications, Function Apps on Windows or Linux with Docker Containers, Mobile Apps, API applications, Web Jobs using Web Deploy / Kudu REST APIs.
- task: AzureRmWebAppDeployment@4
  inputs:
    ConnectionType: 'AzureRM' # 'AzureRM' | 'PublishProfile'. Required. Connection type. Default: AzureRM.
    azureSubscription: # string. Alias: ConnectedServiceName. Required when ConnectionType = AzureRM. Azure subscription. 
    #PublishProfilePath: '$(System.DefaultWorkingDirectory)/**/*.pubxml' # string. Required when ConnectionType = PublishProfile. Publish profile path. Default: $(System.DefaultWorkingDirectory)/**/*.pubxml.
    #PublishProfilePassword: # string. Required when ConnectionType = PublishProfile. Publish profile password. 
    appType: 'webApp' # 'webApp' | 'webAppLinux' | 'webAppContainer' | 'functionApp' | 'functionAppLinux' | 'functionAppContainer' | 'apiApp' | 'mobileApp'. Alias: WebAppKind. Required when ConnectionType = AzureRM. App Service type. Default: webApp.
    WebAppName: # string. Required when ConnectionType = AzureRM. App Service name. 
    #deployToSlotOrASE: false # boolean. Alias: DeployToSlotOrASEFlag. Optional. Use when ConnectionType = AzureRM && WebAppKind != "". Deploy to Slot or App Service Environment. Default: false.
    #ResourceGroupName: # string. Required when DeployToSlotOrASEFlag = true. Resource group. 
    #SlotName: 'production' # string. Required when DeployToSlotOrASEFlag = true. Slot. Default: production.
    #DockerNamespace: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Registry or Namespace. 
    #DockerRepository: # string. Required when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Image. 
    #DockerImageTag: # string. Optional. Use when WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Tag. 
    #VirtualApplication: # string. Optional. Use when WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != functionApp && webAppKind != functionAppLinux && WebAppKind != "". Virtual application. 
    #packageForLinux: '$(System.DefaultWorkingDirectory)/**/*.zip' # string. Alias: Package. Required when ConnectionType = PublishProfile || WebAppKind = webApp || WebAppKind = apiApp || WebAppKind = functionApp || WebAppKind = mobileApp || WebAppKind = webAppLinux || webAppKind = functionAppLinux. Package or folder. Default: $(System.DefaultWorkingDirectory)/**/*.zip.
    #RuntimeStack: # string. Optional. Use when WebAppKind = webAppLinux. Runtime Stack. 
    #RuntimeStackFunction: # 'DOCKER|microsoft/azure-functions-dotnet-core2.0:2.0' | 'DOCKER|microsoft/azure-functions-node8:2.0'. Optional. Use when WebAppKind = functionAppLinux. Runtime Stack. 
    #StartupCommand: # string. Optional. Use when WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer. Startup command. 
  # Post Deployment Action
    #ScriptType: # 'Inline Script' | 'File Path'. Optional. Use when ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script type. 
    #InlineScript: ':: You can provide your deployment commands here. One command per line.' # string. Required when ScriptType == Inline Script && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Inline Script. Default: :: You can provide your deployment commands here. One command per line..
    #ScriptPath: # string. Required when ScriptType == File Path && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Deployment script path. 
  # File Transforms & Variable Substitution Options
    #WebConfigParameters: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Generate web.config parameters for Python, Node.js, Go and Java apps. 
    #enableXmlTransform: false # boolean. Alias: XmlTransformation. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML transformation. Default: false.
    #enableXmlVariableSubstitution: false # boolean. Alias: XmlVariableSubstitution. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. XML variable substitution. Default: false.
    #JSONFiles: # string. Optional. Use when WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. JSON variable substitution. 
  # Application and Configuration Settings
    #AppSettings: # string. Optional. Use when ConnectionType = AzureRM. App settings. 
    #ConfigurationSettings: # string. Optional. Use when ConnectionType = AzureRM. Configuration settings. 
  # Additional Deployment Options
    #enableCustomDeployment: false # boolean. Alias: UseWebDeploy. Optional. Use when ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Select deployment method. Default: false.
    #DeploymentType: 'webDeploy' # 'webDeploy' | 'zipDeploy' | 'runFromZip'. Required when UseWebDeploy == true && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Deployment method. Default: webDeploy.
    #TakeAppOfflineFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType != runFromZip && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Take App Offline. Default: true.
    #SetParametersFile: # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. SetParameters file. 
    #RemoveAdditionalFilesFlag: false # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Remove additional files at destination. Default: false.
    #ExcludeFilesFromAppDataFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Exclude files from the App_Data folder. Default: true.
    #AdditionalArguments: '-retryAttempts:6 -retryInterval:10000' # string. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Additional arguments. Default: -retryAttempts:6 -retryInterval:10000.
    #RenameFilesFlag: true # boolean. Optional. Use when UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Rename locked files. Default: true.

Invoerwaarden

ConnectionType - Verbindingstype
string. Vereist. Toegestane waarden: AzureRM (Azure Resource Manager), PublishProfile (Publicatieprofiel). Standaardwaarde: AzureRM.

Geef het serviceverbindingstype op dat moet worden gebruikt om de web-app te implementeren.

Geef op Publish Profile voor het gebruik van door Visual Studio gemaakte publicatieprofielen.


ConnectionType - Verbindingstype
string. Vereist. Toegestane waarden: AzureRM (Azure Resource Manager), PublishProfile (Publicatieprofiel). Standaardwaarde: AzureRM.

Geef het serviceverbindingstype op dat moet worden gebruikt om de web-app te implementeren.


azureSubscription - Azure-abonnement
Invoeralias: ConnectedServiceName. string. Vereist wanneer ConnectionType = AzureRM.

Geef het Azure Resource Manager-abonnement op voor de implementatie.


PublishProfilePath - Profielpad publiceren
string. Vereist wanneer ConnectionType = PublishProfile. Standaardwaarde: $(System.DefaultWorkingDirectory)/**/*.pubxml.

Het pad van het publicatieprofiel dat is gemaakt vanuit Visual Studio.


PublishProfilePassword - Profielwachtwoord publiceren
string. Vereist wanneer ConnectionType = PublishProfile.

Het wordt aanbevolen om een wachtwoord op te slaan in een geheime variabele en deze variabele hier te gebruiken, bijvoorbeeld $(Password).


appType - App Service type
Invoeralias: WebAppKind. string. Vereist wanneer ConnectionType = AzureRM. Toegestane waarden: webApp (Web-app in Windows), webAppLinux (Web-app op Linux), webAppContainer (Web App for Containers (Linux)), webAppHyperVContainer (Web App for Containers (Windows)), functionApp (Functie-app op Windows (niet aanbevolen, Azure Functions taak gebruiken)), functionAppLinux (Functie-app op Linux (Niet aanbevolen, Gebruik Azure Functions taak)), functionAppContainer (Functie-app voor containers (Linux) (Niet aanbevolen, Gebruik Azure Functions taak) (Niet aanbevolen, Gebruik Azure Functions voor containertaak)), apiApp (API-app), mobileApp (mobiele app). Standaardwaarde: webApp.

Kies uit web-app in Windows, web-app op Linux, web-app voor containers, functie-app, functie-app op Linux, functie-app voor containers en mobiele app.


appType - App Service type
Invoeralias: WebAppKind. string. Vereist wanneer ConnectionType = AzureRM. Toegestane waarden: webApp (Web-app in Windows), webAppLinux (Web App op Linux), webAppContainer (Web App for Containers (Linux)), functionApp (Functie-app in Windows), functionAppLinux (Functie-app op Linux), functionAppContainer (Functie-app voor containers (Linux)), apiApp (API-app), mobileApp (mobiele app). Standaardwaarde: webApp.

Kies uit web-app in Windows, web-app op Linux, web-app voor containers, functie-app, functie-app op Linux, functie-app voor containers en mobiele app.


WebAppName - App Service naam
string. Vereist wanneer ConnectionType = AzureRM.

Geef de naam op van een bestaande Azure App Service. App-services op basis van het geselecteerde app-type worden alleen weergegeven wanneer u de taak assistent gebruikt.


deployToSlotOrASE - Implementeren op site of App Service Environment
Invoeralias: DeployToSlotOrASEFlag. boolean. Optioneel. Gebruik wanneer ConnectionType = AzureRM && WebAppKind != "". Standaardwaarde: false.

Geef de optie op om te implementeren naar een bestaande implementatiesite of Azure App Service-omgeving. Voor beide doelen is voor de taak een resourcegroepnaam vereist. Als het implementatiedoel een site is, is de implementatie standaard de productiesite . Een andere bestaande sitenaam kan worden opgegeven. Als het implementatiedoel een Azure App Service-omgeving is, laat u de sitenaam staan en Production geeft u alleen de naam van de resourcegroep op.


ResourceGroupName - Resourcegroep
string. Vereist wanneer DeployToSlotOrASEFlag = true.

De naam van de resourcegroep is vereist wanneer het implementatiedoel een implementatiesite of een App Service Environment is.

Geef de Azure-resourcegroep op die de hierboven opgegeven Azure App Service bevat.


SlotName - Sleuf
string. Vereist wanneer DeployToSlotOrASEFlag = true. Standaardwaarde: production.

Geef een andere bestaande site dan de productiesite op.


DockerNamespace - Register of naamruimte
string. Vereist wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = webAppHyperVContainer.

Een wereldwijd unieke domeinnaam op het hoogste niveau voor uw specifieke register of naamruimte. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerNamespace - Register of naamruimte
string. Vereist wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppkind = webAppHyperVContainer.

Een wereldwijd unieke domeinnaam op het hoogste niveau voor uw specifieke register of naamruimte. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerNamespace - Register of naamruimte
string. Vereist wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer.

Een wereldwijd unieke domeinnaam op het hoogste niveau voor uw specifieke register of naamruimte. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerRepository - Afbeelding
string. Vereist wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = webAppHyperVContainer.

De naam van de opslagplaats waarin de containerinstallatiekopieën worden opgeslagen. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerRepository - Afbeelding
string. Vereist wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppkind = webAppHyperVContainer.

De naam van de opslagplaats waarin de containerinstallatiekopieën worden opgeslagen. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerRepository - Afbeelding
string. Vereist wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer.

De naam van de opslagplaats waarin de containerinstallatiekopieën worden opgeslagen. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerImageTag - Tag
string. Optioneel. Gebruik wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = webAppHyperVContainer.

Tags zijn het mechanisme dat registers gebruiken om versiegegevens toe te passen op Docker-installatiekopieën. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerImageTag - Tag
string. Optioneel. Gebruik wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppkind = webAppHyperVContainer.

Tags zijn het mechanisme dat registers gebruiken om versiegegevens toe te passen op Docker-installatiekopieën. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


DockerImageTag - Tag
string. Optioneel. Gebruik wanneer WebAppKind = webAppContainer || WebAppkind = functionAppContainer.

Tags zijn het mechanisme dat registers gebruiken om versiegegevens toe te passen op Docker-installatiekopieën. Opmerking: de volledig gekwalificeerde naam van de installatiekopieën heeft de volgende indeling: {registry or namespace}/{repository}:{tag}. Bijvoorbeeld myregistry.azurecr.io/nginx:latest.


VirtualApplication - Virtuele toepassing
string. Optioneel. Gebruik wanneer WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != functionApp && webAppKind != functionAppLinux && WebAppKind != "".

Geef de naam op van de virtuele toepassing die is geconfigureerd in de Azure Portal. Deze optie is niet vereist voor implementaties naar de hoofdmap van de website. De virtuele toepassing moet zijn geconfigureerd voordat het webproject wordt geïmplementeerd.


VirtualApplication - Virtuele toepassing
string. Optioneel. Gebruik wanneer WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != functionApp && webAppKind != functionAppLinux && WebAppKind != "".

Geef de naam op van de virtuele toepassing die is geconfigureerd in de Azure Portal. Deze optie is niet vereist voor implementaties naar de hoofdmap van de website. De virtuele toepassing moet zijn geconfigureerd voordat het webproject wordt geïmplementeerd.


packageForLinux - Pakket of map
Invoeralias: Package. string. Vereist wanneer ConnectionType = PublishProfile || WebAppKind = webApp || WebAppKind = apiApp || WebAppKind = functionApp || WebAppKind = mobileApp || WebAppKind = webAppLinux || webAppKind = functionAppLinux. Standaardwaarde: $(System.DefaultWorkingDirectory)/**/*.zip.

Het bestandspad naar het pakket of naar een map met app-service-inhoud die is gegenereerd door MSBuild of een gecomprimeerd zip- of war-bestand.

Variabelen zijn Build en Release. Jokertekens worden ondersteund.

Bijvoorbeeld $(System.DefaultWorkingDirectory)/\*\*/\*.zip of $(System.DefaultWorkingDirectory)/\*\*/\*.war.


RuntimeStack - Runtimestack
string. Optioneel. Gebruik wanneer WebAppKind = webAppLinux.

Geef het framework en de versie op voor de functie-app in Linux.


RuntimeStackFunction - Runtimestack
string. Optioneel. Gebruik wanneer WebAppKind = functionAppLinux. Toegestane waarden: DOTNET|2.2 (DOTNET|2.2 (functionapp v2)), DOTNET|3.1 (DOTNET|3.1 (functionapp v3)), JAVA|8 (JAVA|8 (functionapp v2/v3)), JAVA|11 (JAVA|11 (functionapp v3)), NODE|8 (NODE|8 (functionapp v2)), NODE|10 (NODE|10 (functionapp v2/v3)), NODE|12 (NODE|12 (functionapp v3)), NODE|14 (NODE|14 (functionapp v3)), PYTHON|3.6 (PYTHON|3.6 (functionapp v2/v3)), PYTHON|3.7 (PYTHON|3.7 (functionapp v2/v3)), PYTHON|3.8 (PYTHON|3.8 (functionapp v3)).

Geef het framework en de versie op. Raadpleeg het overzicht van Azure Functions runtimeversies voor ondersteunde runtimeversies. Oude waarden zoals DOCKER|microsoft/azure-functions-* zijn afgeschaft. Gebruik de nieuwe waarden uit de vervolgkeuzelijst.


RuntimeStackFunction - Runtimestack
string. Optioneel. Gebruik wanneer WebAppKind = functionAppLinux. Toegestane waarden: DOCKER|microsoft/azure-functions-dotnet-core2.0:2.0 (.NET), DOCKER|microsoft/azure-functions-node8:2.0 (JavaScript).

Geef het framework en de versie op.


StartupCommand - Opstartopdracht
string. Optioneel. Gebruik wanneer WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux || WebAppKind = webAppHyperVContainer.

Geef de opdracht Opstarten op. Bijvoorbeeld:

dotnet exec filename.dll

dotnet filename.dll.


StartupCommand - Opstartopdracht
string. Optioneel. Gebruik wanneer WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux || WebAppkind = webAppHyperVContainer.

Geef de opdracht Opstarten op. Bijvoorbeeld:

dotnet exec filename.dll

dotnet filename.dll.


StartupCommand - Opstartopdracht
string. Optioneel. Gebruik wanneer WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux.

Geef de opdracht Opstarten op. Bijvoorbeeld:

dotnet exec filename.dll

dotnet filename.dll.


StartupCommand - Opstartopdracht
string. Optioneel. Gebruik wanneer WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer || WebAppKind = functionAppLinux.

Geef de opdracht Opstarten op. Bijvoorbeeld dotnet rundotnet filename.dll.


StartupCommand - Opstartopdracht
string. Optioneel. Gebruik wanneer WebAppKind = webAppLinux || WebAppKind = webAppContainer || WebAppkind = functionAppContainer.

Geef de opdracht Opstarten op.


ScriptType - Type implementatiescript
string. Optioneel. Gebruik wanneer ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer. Toegestane waarden: Inline Script, File Path (scriptbestandspad).

Hiermee past u de implementatie aan door een script op te geven dat wordt uitgevoerd op de Azure App Service na een geslaagde implementatie. Kies een inline-implementatiescript of het pad en de naam van een scriptbestand. Meer informatie over Azure App Service-implementatie.


ScriptType - Type implementatiescript
string. Optioneel. Gebruik wanneer ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Toegestane waarden: Inline Script, File Path (scriptbestandspad).

Hiermee past u de implementatie aan door een script op te geven dat wordt uitgevoerd op de Azure App Service na een geslaagde implementatie. Kies een inline-implementatiescript of het pad en de naam van een scriptbestand. Meer informatie over Azure App Service-implementatie.


InlineScript - Inlinescript
string. Vereist wanneer ScriptType == Inline Script && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer. Standaardwaarde: :: You can provide your deployment commands here. One command per line..

Het script dat moet worden uitgevoerd. U kunt hier uw implementatieopdrachten opgeven, één opdracht per regel. Zie het volgende voorbeeld


InlineScript - Inlinescript
string. Vereist wanneer ScriptType == Inline Script && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer. Standaardwaarde: :: You can provide your deployment commands here. One command per line..

Het script dat moet worden uitgevoerd. U kunt hier uw implementatieopdrachten opgeven, één opdracht per regel. Zie het volgende voorbeeld


ScriptPath - Pad naar implementatiescript
string. Vereist wanneer ScriptType == File Path && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer.

Het pad en de naam van het script dat moet worden uitgevoerd.


ScriptPath - Pad naar implementatiescript
string. Vereist wanneer ScriptType == File Path && ConnectionType = AzureRM && WebAppKind != "" && WebAppKind != webAppContainer && WebAppkind != functionAppContainer.

Het pad en de naam van het script dat moet worden uitgevoerd.


WebConfigParameters - web.config parameters genereren voor Python-, Node.js-, Go- en Java-apps
string. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war.

Er wordt een standaard Web.config gegenereerd en geïmplementeerd op Azure App Service als de toepassing er geen heeft. De waarden in web.config kunnen worden bewerkt en variëren op basis van het toepassingsframework. Voor node.js toepassingen web.config heeft bijvoorbeeld een opstartbestand en iis_node modulewaarden. Deze bewerkingsfunctie is alleen voor de gegenereerde web.config. Meer informatie over Azure App Service-implementatie.


WebConfigParameters - web.config parameters genereren voor Python-, Node.js-, Go- en Java-apps
string. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war.

Er wordt een standaard Web.config gegenereerd en geïmplementeerd op Azure App Service als de toepassing er geen heeft. De waarden in web.config kunnen worden bewerkt en variëren op basis van het toepassingsframework. Voor node.js toepassingen web.config heeft bijvoorbeeld een opstartbestand en iis_node modulewaarden. Deze bewerkingsfunctie is alleen voor de gegenereerde web.config. Meer informatie over Azure App Service-implementatie.


AppSettings - App-instellingen
string. Optioneel. Gebruik wanneer ConnectionType = AzureRM.

Hiermee worden web-app-toepassingsinstellingen bewerkt met behulp van de syntaxis -key value. Waarden die spaties bevatten, moeten tussen dubbele aanhalingstekens worden geplaatst. Voorbeelden: -Port 5000 -RequestTimeout 5000 en -WEBSITE_TIME_ZONE "Eastern Standard Time". Als u twee of meer sleutelwaarden wilt opgeven, moeten de sleutelwaarden worden gescheiden door een spatie. Bijvoorbeeld: -key1 "Value1" -Key2 "Value2".


ConfigurationSettings - Configuratie-instellingen
string. Optioneel. Gebruik wanneer ConnectionType = AzureRM.

Hiermee bewerkt u configuratie-instellingen voor web-apps met behulp van de syntaxis -key value. Waarden die spaties bevatten, moeten tussen dubbele aanhalingstekens worden geplaatst. Bijvoorbeeld: -phpVersion 5.6 -linuxFxVersion node|6.11.


enableCustomDeployment - Implementatiemethode selecteren
Invoeralias: UseWebDeploy. boolean. Optioneel. Gebruik wanneer ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: false.

Als deze optie niet is ingeschakeld of onwaar, detecteert de taak automatisch de beste implementatiemethode op basis van het app-type, de pakketindeling en andere parameters. Schakel deze optie in de taak assistent in om de ondersteunde implementatiemethoden weer te geven en kies er een voor het implementeren van uw app.


enableCustomDeployment - Implementatiemethode selecteren
Invoeralias: UseWebDeploy. boolean. Optioneel. Gebruik wanneer ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: false.

Als deze optie niet is ingeschakeld of onwaar, detecteert de taak automatisch de beste implementatiemethode op basis van het app-type, de pakketindeling en andere parameters. Schakel deze optie in de taak assistent in om de ondersteunde implementatiemethoden weer te geven en kies er een voor het implementeren van uw app.


DeploymentType - Implementatiemethode
string. Vereist wanneer UseWebDeploy == true && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Toegestane waarden: webDeploy (Web Deploy), zipDeploy (Zip Deploy), runFromZip (Uitvoeren vanuit pakket). Standaardwaarde: webDeploy.

Bepaalt de implementatiemethode voor de app.


DeploymentType - Implementatiemethode
string. Vereist wanneer UseWebDeploy == true && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Toegestane waarden: webDeploy (Web Deploy), zipDeploy (Zip Deploy), runFromZip (Uitvoeren vanuit pakket). Standaardwaarde: webDeploy.

Bepaalt de implementatiemethode voor de app.


TakeAppOfflineFlag - App offline halen
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType != runFromZip && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: true.

Geef deze optie op om de Azure App Service offline te halen door een app_offline.htm bestand in de hoofdmap te plaatsen voordat de synchronisatiebewerking begint. Het bestand wordt verwijderd nadat de synchronisatie is voltooid.


TakeAppOfflineFlag - App offline halen
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType != runFromZip && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: true.

Geef deze optie op om de Azure App Service offline te halen door een app_offline.htm bestand in de hoofdmap te plaatsen voordat de synchronisatiebewerking begint. Het bestand wordt verwijderd nadat de synchronisatie is voltooid.


SetParametersFile - SetParameters-bestand
string. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar.

De locatie van het SetParameters.xml bestand dat moet worden gebruikt.


SetParametersFile - SetParameters-bestand
string. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar.

De locatie van het SetParameters.xml bestand dat moet worden gebruikt.


RemoveAdditionalFilesFlag - Extra bestanden op het doel verwijderen
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: false.

Geef 'true' op om bestanden op de Azure App Service te verwijderen die geen overeenkomende bestanden hebben in het pakket of de map App Service. Hiermee worden ook alle bestanden verwijderd die betrekking hebben op een extensie die op deze Azure App Service is geïnstalleerd. Schakel het Exclude files from App_Data folder selectievakje in om dit te voorkomen.


RemoveAdditionalFilesFlag - Extra bestanden op het doel verwijderen
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: false.

Geef 'true' op om bestanden op de Azure App Service te verwijderen die geen overeenkomende bestanden hebben in het pakket of de map App Service. Hiermee worden ook alle bestanden verwijderd die betrekking hebben op een extensie die op deze Azure App Service is geïnstalleerd. Schakel het Exclude files from App_Data folder selectievakje in om dit te voorkomen.


ExcludeFilesFromAppDataFlag - Bestanden uitsluiten van de map App_Data
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: true.

Geef de optie op om te voorkomen dat bestanden in de App_Data map worden geïmplementeerd naar/verwijderd uit de Azure App Service.


ExcludeFilesFromAppDataFlag - Bestanden uitsluiten van de map App_Data
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: true.

Geef de optie op om te voorkomen dat bestanden in de App_Data map worden geïmplementeerd naar/verwijderd uit de Azure App Service.


AdditionalArguments - Aanvullende argumenten
string. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: -retryAttempts:6 -retryInterval:10000.

Aanvullende argumenten voor Web Deploy volgens de syntaxis -key:value. Deze worden toegepast bij het implementeren van de Azure App Service. Voorbeelden: -disableLink:AppPoolExtension -disableLink:ContentExtension. Meer informatie over web-implementatiebewerkingsinstellingen.


AdditionalArguments - Aanvullende argumenten
string. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: -retryAttempts:6 -retryInterval:10000.

Aanvullende argumenten voor Web Deploy volgens de syntaxis -key:value. Deze worden toegepast bij het implementeren van de Azure App Service. Voorbeelden: -disableLink:AppPoolExtension -disableLink:ContentExtension. Meer informatie over web-implementatiebewerkingsinstellingen.


RenameFilesFlag - Naam van vergrendelde bestanden wijzigen
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: true.

Geef de standaardwaarde op om de vlag MSDEPLOY_RENAME_LOCKED_FILES=1 msdeploy in te schakelen in Azure App Service toepassingsinstellingen. Als deze optie is ingesteld, kan msdeploy de naam wijzigen van bestanden die zijn vergrendeld tijdens de implementatie van de app.


RenameFilesFlag - Naam van vergrendelde bestanden wijzigen
boolean. Optioneel. Gebruik wanneer UseWebDeploy == true && DeploymentType == webDeploy && ConnectionType = AzureRM && WebAppKind != webAppLinux && WebAppKind != webAppContainer && WebAppkind != functionAppContainer && webAppKind != functionAppLinux && WebAppKind != "" && Package NotEndsWith .war && Package NotEndsWith .jar. Standaardwaarde: true.

Geef de standaardwaarde op om de vlag MSDEPLOY_RENAME_LOCKED_FILES=1 msdeploy in te schakelen in Azure App Service toepassingsinstellingen. Als deze optie is ingesteld, kan msdeploy de naam wijzigen van bestanden die zijn vergrendeld tijdens de implementatie van de app.


enableXmlTransform - XML-transformatie
Invoeralias: XmlTransformation. boolean. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Standaardwaarde: false.

De configuratietransformaties worden uitgevoerd voor *.Release.config en *.<EnvironmentName>.config op de *.config file. Configuratietransformaties worden uitgevoerd vóór het vervangen van variabelen. XML-transformaties worden alleen ondersteund voor het Windows-platform.


enableXmlTransform - XML-transformatie
Invoeralias: XmlTransformation. boolean. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Standaardwaarde: false.

De configuratietransformaties worden uitgevoerd voor *.Release.config en *.<EnvironmentName>.config op de *.config file. Configuratietransformaties worden uitgevoerd vóór het vervangen van variabelen. XML-transformaties worden alleen ondersteund voor het Windows-platform.


enableXmlVariableSubstitution - XML-variabele vervangen
Invoeralias: XmlVariableSubstitution. boolean. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Standaardwaarde: false.

Variabelen die zijn gedefinieerd in de build- of release-pijplijn, worden vergeleken met de sleutel- of naamvermeldingen in de configSectionssecties , appSettings, applicationSettingsen connectionStrings van elk configuratiebestand en parameters.xml -bestand. Variabelevervanging wordt uitgevoerd na configuratietransformaties.

Als dezelfde variabelen zijn gedefinieerd in de releasepijplijn en in de fase, vervangen de fasevariabelen de releasepijplijnvariabelen. Meer informatie over [XML-variabele vervangen]](/azure/devops/pipelines/tasks/transforms-variable-substitution#xml-variable-substitution).


enableXmlVariableSubstitution - XML-variabele vervangen
Invoeralias: XmlVariableSubstitution. boolean. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war. Standaardwaarde: false.

Variabelen die zijn gedefinieerd in de build- of release-pijplijn, worden vergeleken met de sleutel- of naamvermeldingen in de configSectionssecties , appSettings, applicationSettingsen connectionStrings van elk configuratiebestand en parameters.xml -bestand. Variabelevervanging wordt uitgevoerd na configuratietransformaties.

Als dezelfde variabelen zijn gedefinieerd in de releasepijplijn en in de fase, vervangen de fasevariabelen de releasepijplijnvariabelen. Meer informatie over [XML-variabele vervangen]](/azure/devops/pipelines/tasks/transforms-variable-substitution#xml-variable-substitution).


JSONFiles - JSON-variabele vervangen
string. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppKind != webAppHyperVContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war.

Biedt een nieuwe, door regels gescheiden lijst met JSON-bestanden om de variabelewaarden te vervangen. Bestandsnamen moeten relatief zijn ten opzichte van de hoofdmap. Als u JSON-variabelen wilt vervangen die genest of hiërarchisch zijn, geeft u deze op met behulp van JSONPath expressies. Als u bijvoorbeeld de waarde van ConnectionString in het onderstaande voorbeeld wilt vervangen, definieert u een variabele met de naam Data.DefaultConnection.ConnectionString in de build- of release-pijplijn (of releasepijplijnfase).

{
  "Data": {
    "DefaultConnection": {
      "ConnectionString": "Server=(localdb)\SQLEXPRESS;Database=MyDB;Trusted_Connection=True"
    }
  }
}

Een variabele vervangen wordt uitgevoerd na configuratietransformaties. Opmerking: Build- en release-pijplijnvariabelen zijn uitgesloten van vervanging. Meer informatie over het vervangen van JSON-variabelen.


JSONFiles - JSON-variabele vervangen
string. Optioneel. Gebruik wanneer WebAppKind != webAppContainer && WebAppkind != functionAppContainer && WebAppKind != webAppLinux && webAppKind != functionAppLinux && Package NotEndsWith .war.

Biedt een nieuwe, door regels gescheiden lijst met JSON-bestanden om de variabelewaarden te vervangen. Bestandsnamen moeten relatief zijn ten opzichte van de hoofdmap. Als u JSON-variabelen wilt vervangen die genest of hiërarchisch zijn, geeft u deze op met behulp van JSONPath expressies. Als u bijvoorbeeld de waarde van ConnectionString in het onderstaande voorbeeld wilt vervangen, definieert u een variabele met de naam Data.DefaultConnection.ConnectionString in de build- of release-pijplijn (of releasepijplijnfase).

{
  "Data": {
    "DefaultConnection": {
      "ConnectionString": "Server=(localdb)\SQLEXPRESS;Database=MyDB;Trusted_Connection=True"
    }
  }
}

Een variabele vervangen wordt uitgevoerd na configuratietransformaties. Opmerking: Build- en release-pijplijnvariabelen zijn uitgesloten van vervanging. Meer informatie over het vervangen van JSON-variabelen.


Opties voor taakbeheer

Alle taken hebben besturingsopties naast hun taakinvoer. Zie Besturingsopties en algemene taakeigenschappen voor meer informatie.

Uitvoervariabelen

Deze taak definieert de volgende uitvoervariabelen, die u kunt gebruiken in downstreamstappen, taken en fasen.

AppServiceApplicationUrl
Toepassings-URL van de geselecteerde App Service.

Opmerkingen

Gebruik deze taak om te implementeren in een reeks App Services in Azure. De taak werkt op platformoverschrijdende agents met Windows, Linux of Mac en maakt gebruik van verschillende onderliggende implementatietechnologieën.

De taak werkt voor webtoepassingen op basis van ASP.NET, ASP.NET Core, PHP, Java, Python, Go en Node.js.

De taak kan worden gebruikt om te implementeren naar een reeks Azure-app Services, zoals:

Vereisten voor de taak

De volgende vereisten moeten worden ingesteld op de doelcomputer(s) om de taak correct te laten werken.

  • App Service exemplaar. De taak wordt gebruikt om een web-app-project of Azure Function-project te implementeren op een bestaand Azure App Service-exemplaar, dat moet bestaan voordat de taak wordt uitgevoerd. Het App Service-exemplaar kan worden gemaakt op basis van de Azure Portal en daar worden geconfigureerd. De Azure PowerShell-taak kan ook worden gebruikt om AzureRM PowerShell-scripts uit te voeren om de web-app in te richten en te configureren.

  • Azure-abonnement. Als u wilt implementeren in Azure, moet een Azure-abonnement zijn gekoppeld aan de pijplijn. De taak werkt niet met de klassieke Azure-serviceverbinding en deze verbindingen worden niet vermeld in de instellingen van de taak.

Gebruiksopmerkingen

  • De taak werkt alleen met de Azure Resource Manager-API's.
  • Als u SSL-fouten wilt negeren, definieert u een variabele met de naam VSTS_ARM_REST_IGNORE_SSL_ERRORS met de waarde true in de pijplijn. Als u implementeert in een site die is geconfigureerd voor automatisch wisselen, mislukt de wisselbewerking, tenzij u of op 1 in SCM_SKIP_SSL_VALIDATION de configuratie-instellingen van App Services instelt.SCM_SKIP_ASE_SSL_VALIDATION
  • Voor .NET-apps die zijn gericht op web-apps in Windows, voorkomt u implementatiefouten met de fout ERROR_FILE_IN_USE door ervoor te zorgen dat de instellingen Naam van vergrendelde bestanden en App offline nemen zijn ingeschakeld. Als u geen downtime wilt implementeren, gebruikt u de optie voor het wisselen van sites.
  • Wanneer u implementeert naar een App Service waarvoor Application Insights is geconfigureerd en u Extra bestanden op bestemming verwijderen hebt ingeschakeld, moet u ook Bestanden uitsluiten van de map App_Data inschakelen om de Application Insights-extensie veilig te houden. Dit is vereist omdat de continue webtaak van Application Insights is geïnstalleerd in de map App_Data.

Implementatiemethoden

Er zijn verschillende implementatiemethoden beschikbaar in deze taak. Web Deploy (msdeploy.exe) is de standaardinstelling. Als u de implementatieoptie wilt wijzigen, vouwt u Aanvullende implementatieopties uit en schakelt u Implementatiemethode selecteren in om te kiezen uit aanvullende implementatieopties op basis van pakketten.

Op basis van het type Azure App Service en agent kiest de taak een geschikte implementatietechnologie. De verschillende implementatietechnologieën die door de taak worden gebruikt, zijn:

De taak probeert standaard de juiste implementatietechnologie te selecteren op basis van het invoerpakkettype, App Service type en het besturingssysteem van de agent.

Logica automatisch detecteren

Voor windows-agents.

App Service type Pakkettype Implementatiemethode
WebApp op Linux of functie-app in Linux Map-/zip-/jar-war
Zip Deploy
War Deploy
WebApp for Containers (Linux) of Functie-app voor containers (Linux) De app-instellingen bijwerken NA
WebApp in Windows, Functie-app in Windows, API-app of mobiele app War
Jar
MsBuild-pakkettype of implementatie in virtuele toepassing


map/zip
War Deploy
Zip Web
Deploy

if postDeploymentScript == true, Zip Deploy
else, Run From Package

Op niet-Windows-agents (voor elk App Service type) is de taak afhankelijk van Kudu REST API's om de app te implementeren.

Web implementeren

Web Deploy (msdeploy.exe) kan worden gebruikt om een web-app in Windows of een functie-app te implementeren op de Azure App Service met behulp van een Windows-agent. Web Deploy biedt veel functies en biedt opties zoals:

  • Naam van vergrendelde bestanden wijzigen: Wijzig de naam van een bestand dat nog in gebruik is door de webserver door de vlag MSDEPLOY\_RENAME\_LOCKED\_FILES=1 msdeploy in te schakelen in de Azure App Service-instellingen. Met deze optie, indien ingesteld, kan msdeploy de naam wijzigen van bestanden die zijn vergrendeld tijdens de implementatie van de app.

  • Extra bestanden verwijderen op bestemming: Hiermee verwijdert u bestanden in de Azure App Service die geen overeenkomende bestanden bevatten in het App Service-artefactpakket of de map die wordt geïmplementeerd.

  • Bestanden uitsluiten van de map App_Data: Voorkomen dat bestanden in de map App_Data (in het artefactpakket/de map die wordt geïmplementeerd) worden geïmplementeerd in de Azure App Service

  • Aanvullende argumenten voor web-implementatie: Argumenten die worden toegepast bij het implementeren van de Azure App Service. Bijvoorbeeld: -disableLink:AppPoolExtension -disableLink:ContentExtension. Zie Instellingen voor web-implementatiebewerkingen voor meer voorbeelden van instellingen voor web-implementatiebewerkingen.

Installeer Web Deploy op de agent vanuit Web Deploy 3.6. Web Deploy 3.5 moet worden geïnstalleerd zonder de gebundelde SQL-ondersteuning. U hoeft geen aangepaste instellingen te kiezen bij het installeren van Web Deploy. Web Deploy is geïnstalleerd op C:/Program Files (x86)/IIS/Microsoft Web Deploy V3.

Kudu REST API's

Kudu REST API's werken op zowel Windows- als Linux-automatiseringsagents wanneer het doel een web-app in Windows, web-app op Linux (ingebouwde bron) of functie-app is. De taak gebruikt Kudu om bestanden te kopiëren naar de Azure-app-service.

Container Registry

Werkt op zowel Windows- als Linux-automatiseringsagents wanneer het doel een web-app voor containers is. De taak werkt de app bij door het juiste containerregister, de juiste opslagplaats, de naam van de installatiekopieën en taggegevens in te stellen. U kunt de taak ook gebruiken om een opstartopdracht door te geven voor de containerinstallatiekopieën.

Zip Deploy

Verwacht een .zip-implementatiepakket en implementeert de bestandsinhoud in de map wwwroot van de App Service- of functie-app in Azure. Met deze optie wordt alle bestaande inhoud in de map wwwroot overschreven. Zie Zip-implementatie voor Azure Functions voor meer informatie.

Uitvoeren uit pakket

Verwacht hetzelfde implementatiepakket als Zip Deploy. In plaats van bestanden te implementeren in de map wwwroot , wordt het hele pakket echter gekoppeld door de Functions-runtime en worden bestanden in de map wwwroot alleen-lezen. Zie voor meer informatie Uw Azure Functions uitvoeren vanuit een pakketbestand.

War Deploy

Verwacht een .war-implementatiepakket en implementeert de bestandsinhoud in de map wwwroot of de map web-apps van de App Service in Azure.

Problemen oplossen

Ik kan niet web implementeren naar mijn Azure App Service met behulp van Microsoft Entra ID verificatie van mijn Windows-agent

De taak Azure App Service implementeren ondersteunt verbinding maken met Microsoft Azure via een ARM-serviceverbinding met behulp van Microsoft Entra ID, tenzij de volgende drie voorwaarden aanwezig zijn:

  • U gebruikt de Web Deploy-pakketindeling op een Windows-agent
  • Uw agent wordt uitgevoerd met een oudere versie van msdeploy.exe (bijvoorbeeld bij gebruik van de installatiekopie van de gehoste windows-2019-agent )
  • Basisverificatie is uitgeschakeld voor uw Azure App Service

Als deze drie voorwaarden aanwezig zijn, ontvangt u een foutmelding zoals App Service is configured to not use basic authentication. This requires Web Deploy msdeploy.exe version 7.1.7225.2108 or higher. You need a version of Visual Studio that includes an updated version of msdeploy.exe. For more information, visit https://aka.ms/azdo-webapp-msdeploy.

Als u dit probleem wilt oplossen, kunt u kiezen uit de volgende opties, op volgorde van voorkeur.

  1. Werk de installatiekopieën van de agent bij. Als u gehoste agents gebruikt, stapt u over van windows-2019 naar windows-2022 (of windows-latest). Als u zelf-hostende agents gebruikt, installeert u Visual Studio 2022 op de agent om een nieuwere versie van msdeploy.exeop te halen.
  2. Als u afhankelijk bent van een oudere agentinstallatiekopieën en de agent voor uw pijplijn niet kunt bijwerken, kunt u overwegen de taak op te splitsen, zodat de Azure App Service de implementatietaak wordt uitgevoerd in windows-2022 (of windows-latest).
  3. Als geen van deze opties mogelijk is, kunt u basisverificatie inschakelen voor uw Azure App Service.

Fout: kan toegangstoken voor Azure niet ophalen. Controleer of de gebruikte service-principal geldig is en niet is verlopen.

De taak gebruikt de service-principal in de serviceverbinding om te verifiëren met Azure. Als de service-principal is verlopen of geen machtigingen heeft voor de App Service, mislukt de taak met deze fout. Controleer de geldigheid van de service-principal die wordt gebruikt en of deze aanwezig is in de appregistratie. Voor meer informatie raadpleegt u Op rollen gebaseerd toegangsbeheer gebruiken voor het beheer van de toegang tot de resources van uw Azure-abonnement. Dit blogbericht bevat ook meer informatie over het gebruik van verificatie van service-principals.

SSL-fout

Als u een certificaat in App Service wilt gebruiken, moet het certificaat zijn ondertekend door een vertrouwde certificeringsinstantie. Als uw web-app certificaatvalidatiefouten geeft, gebruikt u waarschijnlijk een zelfondertekend certificaat. Stel een variabele met de naam VSTS_ARM_REST_IGNORE_SSL_ERRORS in op de waarde true in de build- of release-pijplijn om de fout op te lossen.

Een release blijft lange tijd hangen en mislukt vervolgens

Dit probleem kan het gevolg zijn van onvoldoende capaciteit in uw App Service-abonnement. U kunt dit probleem oplossen door het App Service-exemplaar omhoog te schalen om de beschikbare CPU, RAM en schijfruimte te vergroten of het te proberen met een ander App Service abonnement.

5xx-foutcodes

Als u een 5xx-fout ziet, controleert u de status van uw Azure-service.

Azure-functie werkt plotseling niet meer

Azure Functions kan plotseling stoppen met werken als er meer dan één jaar is verstreken sinds de laatste implementatie. Als u implementeert met 'RunFromPackage' in 'deploymentMethod', wordt een SAS met een vervaldatum van 1 jaar gegenereerd en ingesteld als de waarde van 'WEBSITE_RUN_FROM_PACKAGE' in de toepassingsconfiguratie. Azure Functions gebruikt deze SAS om te verwijzen naar het pakketbestand voor het uitvoeren van de functie, dus als de SAS is verlopen, wordt de functie niet uitgevoerd. U kunt dit probleem oplossen door opnieuw te implementeren om een SAS te genereren met een vervaldatum van één jaar.

Fout: er is geen pakket gevonden met het opgegeven patroon

Controleer of het pakket dat wordt vermeld in de taak, is gepubliceerd als een artefact in de build of een eerdere fase, en is gedownload in de huidige taak.

Fout: publiceren met behulp van zip-implementatieoptie wordt niet ondersteund voor msBuild-pakkettype

Webpakketten die zijn gemaakt via de taak MSBuild (met standaardargumenten) hebben een geneste mapstructuur die alleen correct kan worden geïmplementeerd door Web Deploy. De implementatieoptie publiceren naar zip kan niet worden gebruikt om deze pakketten te implementeren. Voer de volgende stappen uit om de verpakkingsstructuur te converteren:

  1. Wijzig in de taak Oplossing bouwen de MSBuild-argumenten in /p:DeployOnBuild=true /p:DeployDefaultTarget=WebPublish /p:WebPublishMethod=FileSystem /p:DeleteExistingFiles=True /p:publishUrl="$(System.DefaultWorkingDirectory)\\WebAppContent":

    Schermopname van de waarden voor de build-oplossing.

  2. Voeg een archieftaak toe en wijzig de waarden als volgt:

    1. Wijzig de hoofdmap of het bestand om te archiveren in $(System.DefaultWorkingDirectory)\\WebAppContent.

    2. Schakel het selectievakje Naam van hoofdmap prepend om paden te archiveren uit:

      Schermopname van de archiefwaarden.

De web-app-implementatie in Windows is voltooid, maar de app werkt niet

Dit kan komen doordat web.config niet aanwezig is in uw app. U kunt een web.config-bestand toevoegen aan de bron of automatisch een bestand genereren met behulp van bestandstransformaties en opties voor variabelevervanging van de taak.

  • Klik op de taak en ga naar Parameters voor web.config genereren voor Python-, Node.js-, Go- en Java-apps.

    Schermopname van het dialoogvenster Parameters web.config genereren.

  • Klik op de knop Meer web.config parameters genereren voor Python-, Node.js-, Go- en Java-apps om de parameters te bewerken.

    Schermopname van de vervolgkeuzelijst Application Framework.

  • Selecteer uw toepassingstype in de vervolgkeuzelijst.

  • Klik op OK. Hiermee worden web.config parameters ingevuld die nodig zijn om web.config te genereren.

Notitie

Deze sectie is afgeschaft en is vervangen door de taak Bestandstransformatie .

ERROR_FILE_IN_USE

Bij het implementeren van .NET-apps in Web App in Windows kan de implementatie mislukken met foutcode ERROR_FILE_IN_USE. U kunt de fout oplossen door ervoor te zorgen dat de opties Naam van vergrendelde bestanden wijzigen en App offline halen zijn ingeschakeld in de taak. Voor implementaties zonder downtime gebruikt u wisseling van sleuven.

U kunt ook de implementatiemethode Uitvoeren uit pakket gebruiken om te voorkomen dat resources worden vergrendeld.

Fout bij web-implementatie

Als u Web Deploy gebruikt om de app te implementeren, wordt in sommige Web Deploy-scenario's een foutcode weergegeven in het logboek. Zie Foutcodes voor web implementeren om een web-implementatiefout op te lossen.

Web-app-implementatie in ASE (App Service Environment) werkt niet

  • Zorg ervoor dat de Azure DevOps-buildagent zich op hetzelfde VNET bevindt (subnet kan verschillen) als de Interne Load Balancer (ILB) van ASE. Hierdoor kan de agent code ophalen uit Azure DevOps en implementeren naar ASE.
  • Als u Azure DevOps gebruikt, hoeft de agent niet toegankelijk te zijn via internet, maar heeft deze alleen uitgaande toegang nodig om verbinding te maken met Azure DevOps Service.
  • Als u TFS/Azure DevOps Server gebruikt die in een Virtual Network zijn geïmplementeerd, kan de agent volledig worden geïsoleerd.
  • De buildagent moet worden geconfigureerd met de DNS-configuratie van de web-app waarvoor deze moet worden geïmplementeerd. Omdat de privéresources in de Virtual Network geen vermeldingen in Azure DNS hebben, moet deze worden toegevoegd aan het hosts-bestand op de agentcomputer.
  • Als een zelfondertekend certificaat wordt gebruikt voor de ASE-configuratie, moet de -allowUntrusted optie worden ingesteld in de implementatietaak voor MSDeploy. Het wordt ook aanbevolen om de variabele VSTS_ARM_REST_IGNORE_SSL_ERRORS in te stellen op true. Als een certificaat van een certificeringsinstantie wordt gebruikt voor ASE-configuratie, is dit niet nodig. Als u implementeert in een site die is geconfigureerd voor automatisch wisselen, mislukt de wissel, tenzij u of SCM_SKIP_ASE_SSL_VALIDATION op 1 instelt SCM_SKIP_SSL_VALIDATION in de configuratie-instellingen van App Services.

Veelgestelde vragen

Wat is het verschil tussen de AzureWebApp taken en AzureRmWebAppDeployment ?

De Azure Web App-taak (AzureWebApp) is de eenvoudigste manier om te implementeren in een Azure-web-app. Uw implementatie vindt standaard plaats in de hoofdtoepassing in de Azure-web-app.

De Azure App Service De taak Implementeren (AzureRmWebAppDeployment) kan meer aangepaste scenario's verwerken, zoals:

Notitie

Bestandstransformaties en vervanging van variabelen worden ook ondersteund door de afzonderlijke bestandstransformatietaak voor gebruik in Azure Pipelines. U kunt de taak Bestandstransformatie gebruiken om bestandstransformaties en vervangingen van variabelen toe te passen op configuratie- en parametersbestanden.

Hoe moet ik mijn serviceverbinding configureren?

Voor deze taak is een Azure Resource Manager-serviceverbinding vereist.

Hoe moet ik de implementatie van webtaken configureren met Application Insights?

Wanneer u implementeert in een App Service en u Application Insights hebt geconfigureerd en u hebt ingeschakeldRemove additional files at destination, moet u ook inschakelenExclude files from the App_Data folder. Als u deze optie inschakelt, blijft de Application Insights-extensie veilig. Deze stap is vereist omdat de continue WebJob van Application Insights is geïnstalleerd in de map App_Data.

Hoe moet ik mijn agent configureren als deze zich achter een proxy bevindt terwijl ik in App Service implementeer?

Als voor uw zelf-hostende agent een webproxy is vereist, kunt u de agent tijdens de configuratie informeren over de proxy. Hierdoor kan uw agent verbinding maken met Azure Pipelines of Azure DevOps Server via de proxy. Meer informatie over het uitvoeren van een zelf-hostende agent achter een webproxy.

Voorbeelden

Implementeren naar een specifiek app-type

Als u wilt implementeren naar een specifiek app-type, stelt appType u in op een van de volgende geaccepteerde waarden: webApp (Web App on Windows), webAppLinux (Web App on Linux), webAppContainer (Web App for Containers - Linux), functionApp (Function App on Windows), functionAppLinux (Function App on Linux), functionAppContainer (Function App for Containers - Linux), apiApp (API App), mobileApp (Mobile App). Indien niet vermeld, webApp wordt genomen als de standaardwaarde.

Als u geavanceerde implementatieopties wilt inschakelen, voegt u de parameter enableCustomDeployment: true toe en neemt u indien nodig de volgende parameters op.

# deploymentMethod: 'runFromPackage' # supports zipDeploy as well
    # appOffline: boolean    # Not applicable for 'runFromPackage'
    # setParametersFile: string
    # removeAdditionalFilesFlag: boolean
    # additionalArguments: string

Implementeren in Azure Web App Linux-container

In het volgende YAML-voorbeeld wordt geïmplementeerd in een Azure Web App-container (Linux).

pool:
  vmImage: ubuntu-latest

variables:
  azureSubscriptionEndpoint: Contoso
  DockerNamespace: contoso.azurecr.io
  DockerRepository: aspnetcore
  WebAppName: containersdemoapp

steps:

- task: AzureRMWebAppDeployment@4
  displayName: Azure App Service Deploy
  inputs:
    appType: webAppContainer
    ConnectedServiceName: $(azureSubscriptionEndpoint)
    WebAppName: $(WebAppName)
    DockerNamespace: $(DockerNamespace)
    DockerRepository: $(DockerRepository)
    DockerImageTag: $(Build.BuildId)

Een web-app implementeren in een Windows-App Service tussen implementatiesites

In het volgende voorbeeld wordt een web-app geïmplementeerd in een Windows-App Service voor implementatiesites.

pool:
  vmImage: 'windows-latest'

variables:
  solution: '**/*.sln'
  buildPlatform: 'Any CPU'
  buildConfiguration: 'Release'

stages:
 - stage: DeployDevStage
    displayName: 'Deploy App to Dev Slot'
    jobs:
      - job:  DeployApp
        displayName: 'Deploy App'
        steps:
        - task: DownloadPipelineArtifact@2
          inputs:
            buildType: 'current'
            artifactName: 'drop'
            targetPath: '$(System.DefaultWorkingDirectory)'
        - task: AzureRmWebAppDeployment@4
          inputs:
            ConnectionType: 'AzureRM'
            azureSubscription: 'Fabrikam Azure Subscription - PartsUnlimited'
            appType: 'webApp'
            WebAppName: 'partsunlimited'
            deployToSlotOrASE: true
            ResourceGroupName: 'rgPartsUnlimited'
            SlotName: 'Dev'
            packageForLinux: '$(System.DefaultWorkingDirectory)/**/*.zip'

  - stage: DeployStagingStage
    displayName: 'Deploy App to Staging Slot'
    dependsOn: DeployDevStage
    jobs:
      - job:  DeployApp
        displayName: 'Deploy App'
        steps:
        - task: DownloadPipelineArtifact@2
          inputs:
            buildType: 'current'
            artifactName: 'drop'
            targetPath: '$(System.DefaultWorkingDirectory)'
        - task: AzureRmWebAppDeployment@4
          inputs:
            appType: webApp
            ConnectionType: AzureRM            
            ConnectedServiceName: 'Fabrikam Azure Subscription - PartsUnlimited'
            ResourceGroupName: 'rgPartsUnlimited'
            WebAppName: 'partsunlimited'
            Package: '$(System.DefaultWorkingDirectory)/**/*.zip'
            deployToSlotOrASE: true
            SlotName: 'staging'

Voorbeeldscript na implementatie

De taak biedt een optie om de implementatie aan te passen door een script op te geven dat wordt uitgevoerd op de Azure App Service nadat de artefacten van de app zijn gekopieerd naar de App Service. U kunt ervoor kiezen om een inline-implementatiescript op te geven of het pad en de naam van een scriptbestand in uw artefactmap op te geven.

Dit is erg handig als u de afhankelijkheden van uw toepassing rechtstreeks op de App Service wilt herstellen. Het herstellen van pakketten voor Node-, PHP- en Python-apps helpt time-outs te voorkomen wanneer de toepassingsafhankelijkheid ertoe leidt dat een groot artefact van de agent naar de Azure App Service wordt gekopieerd.

Een voorbeeld van een implementatiescript is:

@echo off
if NOT exist requirements.txt (
 echo No Requirements.txt found.
 EXIT /b 0
)
if NOT exist "$(PYTHON_EXT)/python.exe" (
 echo Python extension not available >&2
 EXIT /b 1
)
echo Installing dependencies
call "$(PYTHON_EXT)/python.exe" -m pip install -U setuptools
if %errorlevel% NEQ 0 (
 echo Failed to install setuptools >&2
 EXIT /b 1
)
call "$(PYTHON_EXT)/python.exe" -m pip install -r requirements.txt
if %errorlevel% NEQ 0 (
 echo Failed to install dependencies>&2
 EXIT /b 1
)

Vereisten

Vereiste Beschrijving
Pijplijntypen YAML, klassieke build, klassieke release
Wordt uitgevoerd op Agent, DeploymentGroup
Eisen Geen
Functies Deze taak voldoet niet aan eventuele vereisten voor volgende taken in de taak.
Opdrachtbeperkingen Alle
Instelbare variabelen Alle
Agentversie 2.104.1 of hoger
Taakcategorie Implementeren

Zie ook

  • Deze taak wordt open source op GitHub. Feedback en bijdragen zijn welkom.