Error: failed to solve with frontend when building docker images
I tried searching to see if anyone encountered this challenge and I could not retrieve anything.
I have a simple docker file:
FROM python:3.8
ENV DEBIAN_FRONTEND=noninteractive
ENV LANG en_US.utf8
COPY requirements.txt requirements.txt
RUN python -m pip install --upgrade pip
RUN pip3 install -r requirements.txt
and the docker-compose file:
services:
precipitation_cube:
container_name: ${CONTAINER_NAME}
build:
context: .
env_file: ".env"
volumes:
- "./src:/var/src:ro"
- "./mnt:/var/mnt"
working_dir: /var/src
entrypoint: bash /var/src/startup.sh
restart: unless-stopped
I am running docker-compose build to build the image but I am getting the error below:
Describe the results you received:
failed to solve with frontend dockerfile.v0: failed to build LLB: failed to load cache key: rpc error: code = Unknown desc = error getting credentials - err: exit status 1, out: `Cannot autolaunch D-Bus without X11 $DISPLAY`
ERROR: Service 'precipitation_cube' failed to build
Additional information you deem important (e.g. issue happens only occasionally):
Output of docker compose version:
docker-compose version 1.28.2, build unknown
docker-py version: 4.4.1
CPython version: 3.6.9
OpenSSL version: OpenSSL 1.1.1 11 Sep 2018
Output of docker info:
Client:
Context: default
Debug Mode: false
Plugins:
app: Docker App (Docker Inc., v0.9.1-beta3)
buildx: Docker Buildx (Docker Inc., v0.7.1-docker)
scan: Docker Scan (Docker Inc., v0.12.0)
Server:
Containers: 16
Running: 16
Paused: 0
Stopped: 0
Images: 78
Server Version: 19.03.12
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: journald
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 7b11cfaabd73bb80907dd23182b9347b4245eb5d
runc version: v1.0.2-0-g52b36a2
init version: fec3683
Security Options:
apparmor
seccomp
Profile: default
Kernel Version: 4.15.0-144-generic
Operating System: Ubuntu 18.04.6 LTS
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 15.66GiB
Name: wildfireprocess
ID: YNFH:JM3A:QWTT:4GBS:ELX3:JAKX:F7TZ:6JQH:M5CD:Q4CK:ZFRB:DCEJ
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: true
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: true
WARNING: No swap limit support
Additional environment details: I have tried all options of building the image with no success, what am I doing wrong?
Are you able to build this same Dockerfile when buildkit is enabled?
i.e. run DOCKER_BUILDKIT=1 docker build .
Thanks for replying to the issue. I am getting the same error:
failed to solve with frontend dockerfile.v0: failed to build LLB: failed to load cache key: rpc error: code = Unknown desc = error getting credentials - err: exit status 1, out: `Cannot autolaunch D-Bus without X11 $DISPLAY`
ok, could you please attach your requirements.txt so we get a reproduction scenario and can transfert this issue to the buildkit team?
The contents of the requirements.txt file are as follows:
psycopg2-binary
sqlalchemy
numpy
scipy
pandas
APScheduler
requests
netCDF4
cdsapi
``
[requirements.txt](https://github.com/docker/compose/files/8109181/requirements.txt)
`
Can't reproduce :'(
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
I'm closing this issue as obsolete: Docker Compose V1 has reached end-of-life and we are not accepting any more changes. Please try and reproduce your issue with Compose V2 and create a new issue or PR with the relevant Compose V2 information.