Adding a validation step to our pipeline
Now that we have a fully working pipeline, we should be ready to add the necessary steps to validate and deploy our template. However, first, we need a few variables in our YAML file. Go ahead and add the following variables under the vmImageName
variable, which you can do either by editing the code locally using VS Code or directly in the Azure DevOps portal:
azureServiceConnection: "AzureDevOpsConnection" resourceGroupName: "Bicep" location: "australiaeast" templateFile: "./main.bicep"
Remember that you need to have completed the prerequisite steps and have the service connection at the subscription level created. If the name of your connection is different, simply update the value before adding it to your YAML file. Also, feel free to update your resource group name and location if you wish. Now is the time to add our validation step.
Validating the deployment
Before we add our validation...