Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

JIRA and Bamboo + Bamboo Specs.

We are trying to template our CD/CI pipeline including Deployments using Bamboo Specs.

We use Jira Service Desk for Change Management.

What we currently do is have a script task within the deploy-plan in which we pass the JIRA  issue ID of the CHG to see if it approved and only then allow the deployment else fail it.

This works OK.

But if we have the deploy section also as a part of specs then we cannot inject variable to pass the JIRA issue ID.

we looked into using properties file to inject variables at build stage and this works fine - but then at deploy stage how do we inject a variable - as it is locked by specs ?





1 answer

0 votes

Hi Sar,

As I understand it, you would like the same issue key variable to be used in build and subsequent deploy stage?

I think in this case you can use an inject bamboo variables task in the build stage, with scope set to "Result".

This should mean the variable is available in subsequent deploy stages, and you can use it in any deployment tasks.

Hi Richard, 

We went down this route. But the problem we have is that we may not know the issue key at build time and likely to know this very close to deploy time. 

Trying to inject a variable at a later date will mean running a new build simply to inject a variable to be used in Deploy.

We want to be able to inject variable at deploy time. 


Ah I see, so the problem is that you need to set the variables' value in between the time when the build was run and when the deployment was run.

In Jira Software, I know this can be done when you create a "release build" where you can override the deployment variables. I don't think that can easily work with JSD though, that is documented here for JSW Cloud

Otherwise, I'm not sure how this can be easily done, after a bit of googling, I see this plugin is available: Custom Deployments for Bamboo which seems like it might solve the issue? Note: I have never tried that particular plugin, so cannot attest to it being good or bad.

There is also a feature request to add this to the rest API, which would also solve your problem, consider voting for that if it would be useful: BAM-18838 

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bamboo

Bamboo Data Center 8.1 is now available

G’day Bamboo customers, Bamboo DC 8.1 is now available with it the following features and programs: SAML 2.0, OpenID Connect, and Crowd SSO In order to help admins with a simplified user manage...

160 views 0 4
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you