How to use a Jira version number in a Bamboo build

Howdy,

I'd like to paramatarize my Bamboo builds so that a Jira version number is available in the build to assist with packaging.

For example, In Jira I have a version of '1.1'. I'd like my build.xml use that version number and the bamboo build number the naming of the artefacts. For instance naming my release tar file as 'product-<jira version>.<bamboo build>.tgz'

Thanks,

Simon.

2 answers

1 accepted

When using the JIRA Bamboo plugin and it's release management capabilities, you will have access to the JIRA version as a Bamboo variable.

The following variables are available when the build gets triggered by a JIRA release:

${bamboo.jira.baseUrl}

${bamboo.jira.projectKey}

${bamboo.jira.projectName}

${bamboo.jira.version}

${bamboo.jira.username}

Does the entire build need to be triggered by JIRA to get these variables? I have a build that has four stages, the last of which is a manual stage that I was to trigger from the JIRA release function. I only want to use the JIRA variables in the last stage, but when I triggered the manual step from JIRA, it looks like that variable was not picked up and ${bamboo.jira.version} was left alone while ${bamboo.buildNumber} was replaced correctly.

I am struggling with the exact same behavior... (Bamboo 4 and Jira 5)

Jens - we're on Bamboo 5.6 and JIRA 6.3, would this answer still be relevant? or what should be expected now? As I recall, there's still a pending issue with "JIRA release triggering build", being that you cannot select the branch you wish to release...which is essentially a showstopper. Any help would be appreciated! Regards, Ron

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Organizing your space just got easier - Page Tree Drag & Drop is here

Hi Community! I’m Elaine, Confluence Product Manager. You may have read my earlier post about page tree in space navigation sidebar. I'm excited to share another improvement that helps you organize ...

77 views 3 3
Join discussion

Atlassian User Groups

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!

Find my local user group

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

Groups near you