Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

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

The "Detach container" option does not keep container up after task execution Edited

Hi guys,

I'm using the docker plugin to run a "docker run" by Bamboo with the settings below.

run nginx.JPG

 

my log is this

log.JPG

 

 

The problem I'm facing is that according to the documentation the "Detach container" option should keep the container running in  background (https://confluence.atlassian.com/bamboo0603/configuring-the-docker-task-in-bamboo-939491356.html#ConfiguringtheDockertaskinBamboo-run), but the behavior is different.

 

You can see in the photo below that the container is created but it is destroyed at the end of the terefa. It is also possible to see that I executed the same command generated by the plugin and the container in this case is still online.

docker ps with empty result.JPG

 

 

Anyone have any idea what might be happening?

 

Thank you all!

1 answer

1 accepted

0 votes
Answer accepted

Hi @Marcio_de_Jesus,

Please, have a look at the announcement below, extracted from https://jira.atlassian.com/browse/BAM-17395Docker Task "Detach container" still terminates container, comments section:

Atlassian Update – 18 September 2018

Hi everyone,

Thank you for your interest in this issue. 
While designing Docker Tasks in Bamboo we made a decision that all containers started in background during execution of a job will be terminated at the end of the job. Note that we don't have "terminate container" task.
The checkbox Detach container that we exposed on the UI allows to start container in a task and then use the started container in subsequent tasks (ie. to run tests).

If you're looking for a way to start a container and keep it running after Bamboo job has been completed, you need to run the docker command from the script task.

Please share your feedback in the comments below.

Kind regards,
Bamboo Team

Kind regards,

Rafael

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Bamboo

Bamboo 7.1 is here and is packed with value!

I'm happy to announce that Bamboo 7.1 has been released and it’s overflowing with awesome new features. Top-voted issues First and foremost, a bunch of JAC top voted issues has been delivered - y...

587 views 1 6
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