0
votes

Currently when deploying our Azure functions we make use of the ADO pipeline task to deploy them:

- task: AzureFunctionApp@1
            displayName: 'Deploy Function'
            inputs:
              azureSubscription: 'our sub'
              appType: 'functionApp'
              appName: 'our app'
              deployToSlotOrASE: true
              slotName: 'staging'
              resourceGroupName: 'our-rg'
              package: '$(System.DefaultWorkingDirectory)/Artifact/build$(Build.BuildId).zip'
              deploymentMethod: 'auto'

We have auto-slot-swapping enabled so that, when we deploy, our code goes to our staging slot. This slot is warmed and, if successful, the slot is swapped into live.

Unfortunately this ADO task has no way of knowing if the slot swap was actually successful. The only visibility of this is in the Azure Portal activity log, and these logs show whether the swap was successful or not (and the code actually went live).

Is there a simple for approach for us to know from the ADO pipeline whether the swap was successful?

1
Post-deployment gate that checks Azure resource monitor?Daniel Mann

1 Answers

0
votes

You could use Azure App Service Manage task to swap slot instead of enabling auto-slot-swapping. In this way, you could get the slot swapping status.