3

I'm quite new to Azure Devops, so sorry if it's obvious questions. I have a release pipeline with 3 stages like this: Release pipeline

First stage is run on Agent A on Machine A, Stages 2,3 run on Agent B on Machine B. Once stage 1 in prev. pipeline is finished -> it will start stage 1 of next scheduled pipeline run. Is there a way to prevent this? I would like to start next scheduled pipeline run only after all stages are finished in previous one.

Mike
  • 931
  • 1
  • 8
  • 15
  • I think it might help you: https://stackoverflow.com/questions/58709812/how-to-check-if-a-previous-release-has-been-completed-before-deploying-a-new-rel/58712024#58712024 – Shayki Abramczyk Oct 12 '21 at 06:57

3 Answers3

0

You can add Dependencies: If you are using YAML: https://learn.microsoft.com/en-us/azure/devops/pipelines/process/stages?view=azure-devops&tabs=yaml

IF you are using classic pipelines you can use "Pre deployment Condition" https://learn.microsoft.com/en-us/azure/devops/pipelines/release/define-multistage-release-process?view=azure-devops

Also you can use approval gate if you want manual intervention. https://learn.microsoft.com/en-us/azure/devops/pipelines/release/approvals/?view=azure-devops

  • Thanks for answer. I'm using classing pipelines. I could not find anything in "Pre-Deployment condition" . Do you know which feature there could help me in m y case? – Mike Oct 12 '21 at 04:50
0

According to Specify queuing policies, this is not currently possible except for using manual intervention.

YAML pipelines don't support queuing policies. Each run of a pipeline is independent from and unaware of other runs. In other words, your two successive commits may trigger two pipelines, and both of them will execute the same sequence of stages without waiting for each other. While we work to bring queuing policies to YAML pipelines, we recommend that you use manual approvals in order to manually sequence and control the order the execution if this is of importance.

angularsen
  • 8,160
  • 1
  • 69
  • 83
0

You can use Post-Deployment approvals: enter image description here

or Pre-Deployment approvals:

enter image description here

Shamrai Aleksander
  • 13,096
  • 3
  • 24
  • 31