Last updated: Jul 26, 2020 12:59
Add Bamboo job parameters
Bamboo provides some default variables, such as job name, build number, or plan name. For the complete list of Bamboo variables, see here.
You can use Bamboo variables to provide the Job Name and Job Number parameters to the Smart Reporting feature.
To access these variables, use the following format within your code:
Instead of variableName, use shortJobName and buildNumber to retrieve both and then pass them to the Reporting Client.
Supply Maven or Ivy parameters
If you run your tests using Maven or Ivy, add the following JVM parameters and (optionally) the Report-tags parameter, as follows:
You need to supply the myTag and myBranch values (see Add variables below). Bamboo automatically supplies the bamboo.shortJobName and bamboo.buildNumber values.
CustomField pairs, use the following format:
To locate your parameters:
- In Bamboo, in your Build Dashboard list, find your project and click it. The page with the plan summary opens.
- In the top right corner, click the gear icon and select Plan Configuration.
- In the middle of the page, on the Stages tab, under Default Stages, click your job. The new page loads.
- On the Tasks tab, click Maven. Your Maven configurations display in the right panel, including your goals.
Add your parameters here:
Add variables - tags
Bamboo provides a way to inject variables and use them in your project with the Bamboo Inject Variables Plugin.
To do this, add a new Inject Bamboo variables task and specify the path to the properties file from your source control (Git/svn).
The properties file should be in the following format: