Can I use bamboo plan variables in a deployment project?

Viewed 3852

I would like to use a bamboo plan variable in a deployment project.

I inject the version of the project into ${bamboo.inject.version} during the build plan, and I would like to use it in the deployment project. (The artifact I am deploying uses the version in its name).

I've tried referencing ${bamboo.planRepository.inject.version} and ${bamboo.inject.version} but neither of these work.

I am happy to hear suggestions of other ways of doing this too.

Edit: I did manage to achieve the results I wanted by adding the properties file as a build artifact, then exporting it into the deployment project. This seems rather roundabout but works. Any other ideas appreciated!

2 Answers

As suggested by ToAsT, set the scope of your injected variables to Result first, then add a variable inject.version into your plan, and make sure you also have ${bamboo.inject.version} for release versioning field of the deployment project.

Related