Cancel previous release azure pipeline yaml
Asked Answered
S

2

11

When creating a release pipeline via the UI (Release) in Azure Devops you have the option cancel previous release.

Deploy latest and cancel the others

How can i create this with YAML in my release pipeline, now as you can see al the previous releases are still waiting

YAML exampel

Schweiz answered 13/2, 2020 at 16:10 Comment(0)
Z
13

Cancel previous release azure pipeline yaml

For this issue ,I am afraid it is currently not supported in yaml.

From this document , we can know that: Queuing policies are not yet supported in YAML pipelines.

enter image description here

Subsequent releases setting is also part of the Deployment queue settings. So Deploy latest and cancel the others should also not be supported at present, and can only be implemented in classic pipeline.

Apart from the negative answer, I think what you want is a good idea! So I post a feature request here in DC forum. Anyone interested in this can vote for it and track it. You could also vote that suggestion ticket and share your comment there.The product team would provide the updates if they view it. Hope this helps.

Zea answered 14/2, 2020 at 10:43 Comment(0)
L
0

I found this pipeline extension.

This extension aims to emulate the "Deploy latest and cancel the others" capability for YAML multi-stage pipelines.

It will auto-cancel older pipelines when a newer build completes successfully - which means after you approve to deploy to production, all other runs still waiting for approval will be cancelled.

Lavernlaverna answered 28/10, 2023 at 9:22 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.