Yes, you can configure your plan branch to use any repository branch you want to. For more information, please refer to this page.
By the way, if you just want to checkout from the master branch and don't need other branch plan featuers, you can configure a specific branch (by default Bamboo uses the master branch) on the repository configuration page of a regular plan. For instance, if you use Git, you can specify the branch in the Branch field as it's mentioned in the documentation.
Currently Bamboo doesn't support conditional flow controls. You can achieve a similar goal by splitting your current plan into 2 plans (the one that contains the build & package part, and the other one that contains the rest). Next, add a Script task to be the last task in your first plan. In your script task write a small script that will check the plan variable that returns the branch name (bamboo.repository.branch.name), and if the branch name is not a specific one, use this command to trigger the second plan:
curl -X POST --user admin:admin "http://localhost:8085/rest/api/latest/queue/FOO-BAR?executeAllStages=true"
where "admin:admin" is the username and password, and "FOO-BAR" is the plan key you want to trigger. I know this doesn't look the exact action that you ment, but as I said, Bamboo doesn't support conditional controls.
I would not recommend the above if using Bitbucket (or Stash) with Pull Requests.
Only the very first plan triggered by a code change will then report a "Successful Build" to Bitbucket; therefore someone could easily think a build was successful, only to find that the subsequent plan actually failed.
These steps work in Bamboo 5.12. I have no idea what other versions of Bamboo are like.
1. In the Bamboo build plan, navigate to the Branches tab and select "Create plan branches for matching new branches" and add a regular expression, for example "^feature/". Or you can select "Create plan branches for all new branches" and skip the regular expression.
2. If there isn't already a branch plan for master, add it manually using the "Create plan branch".
3. Navigate to the Branch details tab for the master branch plan and change the trigger type to manual.
I'm trying to configure a plan to exclude branches that start with "hotfix". I'm using "Only create branches that match" "^((?!hotfix).)*$", but that plan still executes on branches like hotfix/ABC or hotfix-ABC.
Is this a bug on Bamboo or my regexp is not right (although all regexp parsers exclude strings like hotfix/ABC or hotfix-ABC on that regexp)?
The regex is for creating plan branches, not for running them. If you create a branch in your repository and you want Bamboo to detect and automatically add the corresponding plan branch, that's when the configured regex will be used. However, if the plan branch is already created in Bamboo, the branch will run whenever it's triggered. Makes sense?
I’m a designer on the Jira team. For a long time, I’ve fielded questions from other designers about how they should be using Jira Software with their design team. I’ve also heard feedback from other ...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs