...
It's rare that an organisation would want a Git commit to be automatically promoted all the way to Production; most organisations would want at least one part of the delivery pipeline to require a manual approval. Fortunately this can be easily configured in Azure DevOps.
Configuring a Manual Approval Check
In your Azure DevOps project, go to the resource (ie. environment) that needs to be protected.
Navigate to Approvals and Checks for the resource.
Select [+] to create a check and select Approvals then Next.
Provide the approvers and an optional message, and select Create to complete addition of the manual approval check.
...
When you run a pipeline the execution of that run pauses before entering a stage that uses the environment. Each stage’s environment requirements are specified using the environment key as a property of a deployment job. The example below is taken from the pipeline that ships with MettleCI where the environment name is parameterised:
Code Block |
---|
... jobs: - deployment: Deploy_${{ parameters.EnvironmentID }} displayName: Deploy to ${{ parameters.EnvironmentName }} pool: 'My Agent Pool Name' environment: ${{ parameters.EnvironmentName }} strategy: runOnce: deploy: steps: ... |
...
On this page you can click Review to display the approval dialog where you can enter a comment before clocking clicking Approve or Reject.
...
If you have configured Azure DevOps Teams Integration you will also receive a post in your Teams channel from which you can also submit your approval by clicking Approve:
...