Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure DevOps release pipeline with git-flow

I'm attempting to configure a release pipeline in Azure DevOps (on premises) to support a git-flow strategy. What I'm trying to achieve:

  1. Commits to 'release/*' trigger a build of the software and publish to a location for QA
  2. Commits to 'master' take the same software build (artifact) from step 1 and publish to Production location

So when I do a git-flow 'start release' the software is made available for testing/QA and when I 'finish release' it's made available to users.

My build pipeline works fine, it's triggered by the release branch and concludes with a Publish Artifact task. My release pipeline uses this artifact and has stages for QA and Production but the Production stage never triggers. For QA I've got an artifact filter for 'release/*' and on Production for 'master'.

Is there a way to trigger my second release pipeline stage on a commit to 'master'?

like image 473
Colin Baker Avatar asked Oct 19 '25 04:10

Colin Baker


1 Answers

As a general flow this won't work unfortunately. When you commit to release branch your building from release branch. When you commit to master branch you will have to build again for an artifact to be oriented from a master commit.

You'll either need to be happy with:

  • 1 x build from commit to release OR master and release to both environments
  • 2 separate builds for release to separate environments
like image 87
Bevan Avatar answered Oct 22 '25 05:10

Bevan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!