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

unable to prepare context: unable to evaluate symlinks in Dockerfile path: lstat /opt/atlassian/pipe

I would like to use bitbucket pipelines. I configure pipelines file but i have this error: 

unable to prepare context: unable to evaluate symlinks in Dockerfile path: lstat /opt/atlassian/pipelines/agent/build/Dockerfile: no such file or directory

 

here is my config file:

image: maven:3.3.9

options:
  docker: true
  
pipelines:
  branches:
    develop:
      - step:
          caches:
            - maven
          script:
            - export IMAGE_NAME=$DOCKER_HUB_USERNAME/$DOCKER_HUB_APP_NAME:$BITBUCKET_COMMIT      
            - docker build -t $IMAGE_NAME .
            - docker login --username $DOCKER_HUB_USERNAME --password $DOCKER_HUB_PASSWORD
            - docker push $IMAGE_NAME
          services:
            - database

definitions:
  services:
    database:
      image: mysql
      environment:
        MYSQL_ROOT_PASSWORD: password

 

Any help please!

6 answers

I am having the same issue. 

All I did was use the default docker pipeline script (and swapped out the placeholders) and I am getting the same error. 

I've got the same problem. @Sean Robinson @DIALLO Alpha Oumar Kona did you find any solution?

I've got the same issue, we only copied the pipeline example from bitbucket and doesn't work.

One suggestion - try adding `ls -lR` to one of your build steps. Perhaps you are actually missing the file in the folder where the build is run?

This helped me with my problems.

I have the same issue... and I have the DockerFile in root dir (working space in Pipeline).

¿Any idea?

0 votes

Hey guys, i was having similar issue - 

What i realize is that, my dockerfile name was DockerFile [in the repo] but bitbucket pipeline is looking for Dockerfile. 

If this is the case just rename DockerFile to Dockerfile 

Thanks me later 

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 Mar 14, 2019 in Bitbucket Pipelines

Building a Bitbucket Pipe as a casual coder

...ipe.sh :  #!/bin/bash source "$(dirname "$0")/common.sh" enable_debug extra_args="" if [[ "${DEBUG}" == "true" ]]; then extra_args="--verbose" fi # mandatory variables R...

1,010 views 1 16
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