I have a YAML-based, Azure DevOps pipeline. Within that pipeline I have stages each representing a deployment to an environment. This includes provisioning of infrastructure in Azure, deloyment of the app and running automated acceptance tests.
It's possible for engineers to run manual pipelines from multiple branches as well as have the master branch triggered pipeline all running in parallel. This means an environment deployment stage can be running in parallel across multiple running instances of the pipeline.
I'd like to have a stage wait to be the only instance running. What's the best way to solve this with YAML pipelines?
dependsOn: []
property to your stages will cause them run in parallel. Or if i misunderstood your question? – Yang Shen - MSFT