Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Triggering builds on pull requests - different plans for different target branch

Mariusz Dullak June 16, 2020

Hi all,

some background:

I am given the tasks to stop certain team from pushing directly to particular branches: develop, system_2, system_3.

Those branches have code for different devices that shares the HW partially.

So build plan and build environment for develop is completely different (like different Linux distro) then system_2 and system 3.

They all have their respective build plans and it all works with commit detection etc.

Now I want (task given by higher power ;-)) to force them to start using pull requests and to configure everything in a way that the pull requests can be only made when:

- commit message links to JIRA (easy, done)

- proper credentials and author == committer (easy done)

- code on target branch will still builds after the merge - this is where I have a problem.

 

So I have 3 build plans:

- commit to develop

- commit to system_2

- commit to system_3

they do what they say they do. They are all set to branch when pull request is created.

Now when I create a brach: test, so some changes, push them and I am creating pull request from my branch test to system_2 (and my change is just this one commit, no other changes and I can see it is true when I am creating pull request), bamboo is triggering ALL 3 builds. system_2 build passes, other two fails.

 

How to I configure Bamboo and/or BitBucket that it only creates and runs the plan for the branch I am trying to merge to via this pull request?

 

Thanks in advance.

 

PS. At this point I am not allowed (yet?) to enforce changes in branch naming and/or separation of those branches to different repos.

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events