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
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Renan Battaglin
Published May 18, 2017 in Bamboo

FAQ: How to Upgrade Bamboo Server

Bamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...

1,319 views 0 5
Read article

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