How to poll bamboo from external tool for bamboo results?

I have got a project working that uses REST call to trigger a bamboo build

curl --user $BAMBOO_USER:$BAMBOO_PASS -X POST -d "$STAGE_NAME&ExecuteAllStages"http://mybamboohost:8085/rest/api/latest/queue/$PROJECT_NAME-$PLAN_NAME

So as soon this is curl command is triggered, my project passes and does not wait to get results from bamboo build.

How I can poll the bamboo from an external tool to see if the bamboo build passed or failed. Is there a curl command I can use to continously poll the bamboo build?

1 answer

Bamboo Command Line Interface has queueBuild which supports a wait parameter. You could do something similar using curl and some scripting checking the build number.

Thanks Bob. Is there a way I can introduce the wait through a rest call?

I want to know whether the build passed or failed.

example - rest/api/latest/queue/$PROJECT_NAME-$PLAN_NAME?bamboo.variable.exitCode=0

Not that I know of, you need to poll on the build number and then get the build results.

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,315 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