Bamboo cli taskKey list

Hi,

I am trying to use the bamboo cli but don't know what can be used as a taskKey.

Is there a list of taskKeys or a way to figure out what the key for each task is?

4 answers

1 accepted

One way is to go into the Task browser and look at the link for the task you are interested in.

Hi Bob,

Looking at the task browswer, I copied the Task's link address (right on the task, copy link address) and here is what I get:

http://<bamboo install address>/build/admin/edit/addTask.action?planKey=INTEST-RSRHEL532-JOB1&returnUrl=%2Fbuild%2Fadmin%2Fedit%2FeditBuildTasks.action%3FbuildKey%3DINTEST-RSRHEL532-JOB1&createTaskKey=com.atlassian.bamboo.plugins.vcs%3Atask.vcs.checkout

From this I gather the TaskKey = com.atlassian/bamboo.plugins.vcs:task.vcs.checkout

Am I right?

Yes, that should be it. Except for the typo: com.atlassian.bamboo.plugins.vcs:task.vcs.checkout

Thanks Bob that seems to work.

I have 2 follow up questions:

1.I don't see the updated changes in my plan. The output of the command line:

abhi@penny /abhi/bamboo-cli-3.1.0 $ ./bamboo.sh --action addTask --build "INTEST-RHEL532" --job "JOB1" --taskKey "com.atlassian.bamboo.plugins.vcs:task.vcs.checkout" --description "Checkout Test" --field1 "Repository" --value1 "Plan Repository"

Source Code Checkout task with id 47 added to job INTEST-RHEL532-JOB1.

abhi@penny /abhi/bamboo-cli-3.1.0 $ ./bamboo.sh --action addTask --build "INTEST-RHEL532" --job "JOB1" --id "1" --taskKey "com.atlassian.bamboo.plugins.vcs:task.vcs.checkout" --description "Checkout Test" --field1 "Repository" --value1 "Plan Repository"

Source Code Checkout task with id 48 added to job INTEST-RHEL532-JOB1.

How can I check if the plan actually has these tasks but the GUI screen isn't seeing

2. When I specify a "command" as the task, it doesn't know which "command" I am trying to add. I have tried to set the "fields" and "field1" to no success. Can you take a look at my command line and see what the problem is?

abhi@penny /abhi/bamboo-cli-3.1.0 $ ./bamboo.sh --action addTask --build "INTEST-RHEL532" --job "JOB1" --id "1" --taskKey "com.atlassian.bamboo.plugins.scripttask:task.builder.command" --description "Move top-level makefile" --fields "Argument:aaaa, EnvironmentVariables:eee=vvv" --field1 "Executable" --value1 "gmake"

Remote error: Please specify the command.

abhi@penny /abhi/bamboo-cli-3.1.0 $ ./bamboo.sh --action addTask --build "INTEST-RHEL532" --job "JOB1" --id "1" --taskKey "com.atlassian.bamboo.plugins.scripttask:task.builder.command.gmake" --description "Move top-level makefile" --fields "argument:aaaa, environmentVariables:eee=vvv" --field1 "executable" --value1 "gmake"

Remote error: unknown

abhi@penny /abhi/bamboo-cli-3.1.0 $ ./bamboo.sh --action addTask --build "INTEST-RHEL532" --job "JOB1" --id "1" --taskKey "com.atlassian.bamboo.plugins.scripttask:task.builder.command" --description "Move top-level makefile" --fields "executable:gmake, argument:aaaa, environmentVariables:eee=vvv" --field1 "executable" --value1 "gmake"

Remote error: Please specify the command.

abhi@penny /abhi/bamboo-cli-3.1.0 $ ./bamboo.sh --action addTask --build "INTEST-RHEL532" --job "JOB1" --id "1" --taskKey "com.atlassian.bamboo.plugins.scripttask:task.builder.command:gmake" --description "Move top-level makefile" --fields "executable:gmake, argument:aaaa, environmentVariables:eee=vvv" --field1 "executable" --value1 "gmake"

Remote error: unknown

abhi@penny /abhi/bamboo-cli-3.1.0 $ ./bamboo.sh --action addTask --build "INTEST-RHEL532" --job "JOB1" --id "1" --taskKey "com.atlassian.bamboo.plugins.scripttask:task.builder.command:executable.gmake" --description "Move top-level makefile" --fields "executable:gmake, argument:aaaa, environmentVariables:eee=vvv" --field1 "executable" --value1 "gmake"

Remote error: unknown

  1. If it isn't showing up in the UI, then that says it probably wasn't added :(. Open an issue with more details. Specifically what Bamboo version are you on. Then I can look at the details.
  2. Each task type has different parameters that are required.

How do I know which parameters are required per task?

Usually, it is obvious by looking at the task UI. In the command case, it is know as label under the covers and shows as Environment on the display.

I have added more details in the issue you created - BCLI-28

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Tuesday in Uncategorized

Friday fun: how many celebrates Midsummer holiday or is this a Swedish tradition only?

Any other country that celebrates Midsummer holiday (this friday 22 June)?  

36 views 3 1
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