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

Docker build command hangs in bitbucket pipeline

Stephen Poserina
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 6, 2024

I'm trying to set up a CI/CD pipeline using Bitbucket Pipelines. I have a simple yml file that issues a Docker build command. The build command starts correctly with log statements similar to what it looks like when building locally with docker. The docker command hangs indefinitely only failing after the pipeline timeout is exceeded. I tried increasing the memory allocated to the docker service to 8G but the issue persists.  I don't believe it should need more memory than that since we are currently using Azure DevOps to build the same Docker image with default settings.  I've tried to build two separate Docker files both resulting in the same hanging/timeout error.

1 answer

1 vote
Patrik S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 7, 2024

Hello @Stephen Poserina and welcome to the Community!

I would like to ask you a few questions to help us investigate the issue you are facing:

  • Are you running your build atlassian infrastructure, or are you using self-hosted runners? If using runners, what type of runners (linux docker, linux shell, etc)?
  • Could you share with us
    • the full docker build command you are executing
    • the latest logs that are printed in the pipelines before the build hangs
    • the full command in the Dockerfile step where the build hangs.

This will help us narrow down the issue and provide you with more accurate instructions.

Thank you, @Stephen Poserina !

Patrik S

Stephen Poserina
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 19, 2024

Hi Patrick

I was able to figure out the problem on my end. I had the yaml hierarchy incorrect. I specified the following to increase memory. This does not cause errors but does not increase the amount of memory provided to the Docker process.

definitions: 
docker:
memory: 2048

 

 

Like Sabine Mayer likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events