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

Log shows build failed but Bamboo said Build Sucessful

Mary Hsieh Dec 05, 2012

I'm new to Bamboo and I'm using a windows command line script to do my build. I can clearly see the in the log that the build failed.

error 05-Dec-2012 15:08:08 ecomarm: fatal: No license available for "source_analysis"
error 05-Dec-2012 15:08:08
error 05-Dec-2012 15:08:10 Error: build failed

However, the Bamboo notification tells me the build is successful. Why is that and how can I fix it?

I'm using Bamboo 4.2.1

3 answers

2 accepted

0 votes
Answer accepted
Mary Hsieh Dec 10, 2012

The script always exits with 0 since the script itself executed normally. What was done originally was all the project builds are combined into one script file. It looks like Bamboo only looks at the last few lines of the script results. So if the script failed in the middle, then it will not catch it. So what had to be done was to split up each project build into its own Bamboo task so Bamboo can detect the failure. A little cumbersome but at least it worked. Maybe the task section in the documentation explained this. Sorry if I missed it.

0 votes
Answer accepted
Nick Hilton Apr 26, 2017

For others arriving from search engines, one can use

{code}

set -e

{code}

At the top of their script so it errors out on any error.

0 votes
Przemek Bruski Atlassian Team Dec 05, 2012

The script has to exit with a non zero status for the build to fail.

Brian Mackey May 08, 2015

How do you see what the script reports or modify it?

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published in Opsgenie

Handling Opsgenie Alerts

Hi everyone, welcome to the kb articles for Opsgenie FAQs. I'm one of the Technical Support Engineers for Opsgenie who will be providing weekly posts on FAQs from customers.   All alerts are ...

64 views 0 3
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