-
Notifications
You must be signed in to change notification settings - Fork 291
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Canceled: context cancelled while "load build context" #13812
Comments
I figure this problem came in recent versions of docker. |
I'm having this same problem on Docker Desktop 4.26.1 on Windows 11, I found a thread that said to downgrade to Docker Desktop 4.22 and that fixed the problem. So it is a problem with the never versions of docker like @randercarlos said. I tried installing Docker Desktop 4.23 and the problem came back. So the bug was introduced in 4.23. ERROR:
compose-dev.yaml:
Dockerfile.frontend:
|
will someone solve the problem? |
You must use a Docker version 4.22 or below to solve the problem. |
does this look like a solution?? 😠 |
If you think it is or isn't a solution, that's not my problem!!! I used this solution, and it worked for me. |
If you are using WSL engine in your docker desktop app, you must run the docker compose command inside it eg |
I’ve experienced this issue as well on Windows 11. Downgrading to Docker 4.22 “solved” it. I’ve confirmed in line with this Stack Overflow thread that the issue was not due to other programs holding on to the files. Running commands within WSL did not solve it for me. This is a major issue; recent versions are entirely unusable because I cannot build images with them. |
downgrading is a crutch and not a solution to the problem |
I agree with you @DimIsaev. It’s not a real solution. We need a fix. |
The purpose of this thread is to provide a solution for docker's users who have the problem mentioned in the issue's title. Whoever wants to fix the bug, He should ask the Docker's team. |
I agree with you @ndmekala . We need a fix. |
Hello there 👋 |
On the original issue Compose try to build |
@Glorus |
For those who are impacted by this issue can you share minimal reproduction steps and a diagnostics id? You can generate one from the terminal. See https://docs.docker.com/desktop/troubleshoot/overview/#diagnose-from-the-terminal |
I encountered this error today after upgrading to 4.27.1. I downgraded to 4.22.1 and the issue went away. |
Docker Desktop |
@glours |
I'm experiencing this issue as well. I initially went back to Docker Desktop 4.22, but found that I could upgrade to 4.25.2 as the last working version. Docker Desktop 4.26.0, 4.26.1, 4.27.0, 4.27.1, and 4.27.2 all had the issue. I uninstalled Docker Desktop and did the following, capturing a few diagnostics along the way as requested by @bsousaa
I'm using this Dockerfile: https://github.com/FalconChristmas/fpp/blob/master/Docker/Dockerfile |
Issue still exist for me even after upgrading to 4.27.2. |
I also tried updated to 4.27.2 and am still having the same issue. |
I get this error, with 4.27.2 I had just upgrading a dockerfile to .net8, I got the above error, I then tried with a old .net7 code branch and it worked.. Downgraded to 4.22, and both branches build ok |
Good suggestion @ValentinNikolaev! I ended up with an interesting result. I installed Docker Desktop 4.27.2 and tried my build from PowerShell, which failed, then from WSL, which worked fine. Hopefully, this will help debugging while also being a possible workaround.
|
Just ran into this thread, still having this issue with 4.27.2 running from powershell and WSL, exact same behavior as @ValentinNikolaev above in both scenarios for me. |
I've updated to v4.28.0 and am still experiencing the same issue as v4.27.2 when running docker build from PowerShell, but it still works fine from WSL. PS C:\Users<username>\Documents\GitHub\fpp> docker buildx version |
I had this exact issue using Pycharm. When I
Running it from PowerShell gave a more helpful error:
So Github Copilot was causing the problem. I added .idea to .dockerignore (which I should've done anyway, but hey-ho) and it worked fine. |
Wow! Exactly at this moment I am having the same issue, googled and stumbled over the comment that is literally 5 minutes old. Thank you!! Adding the .idea folder to the .dockerignore solved the issue for me. |
Adding .idea to the dockerignore solved it. I noticed some new copilot related files in the .idea folder recently and they also interfered with git before jetbrains automatically added them to the gitignore inside the .idea folder. |
Thanks folks! For my TYPO3 project it was a symbolic link in |
Thanks @taco-killchain , adding .idea to the dockerignore solved it. |
add the docker volumes to dockerignore solve it for me |
So Dockerfile doesn't overwrite .idea? |
I've been encountering the same errors and stumped for weeks, but I finally got it to work even with the latest Docker Desktop for Windows (4.28.0) by specifying
|
in my case works when i add **/.idea in .dockerignore |
Good evening, I have the same problem, I tried to put .idea in dockerignore but nothing changes, I have the problem all the time. Another solution ? |
@AlxHer
NOTE
or
|
Sorry @ts5h , I tried everything, it doesn't work. I am under W11 and V4.28 |
@AlxHer did you try to add volumes created by container to dockerignore? |
my Dockerfile:
And when I look at the problem it comes from the |
@AlxHer yeah thats a file permission issue, with .idea / node_modules/ vendor / any docker volumes which is in the same folder as your project files |
Same symptoms here.
However the following does not fail on the same step:
So I decided to call docker directly from under WSL (ubuntu 22.04):
That solved the symptoms for me... For reference:
Another way to solve the symptoms:
ref: |
For Rstudio users, this issue was solved in my project by adding |
I solve problem with this |
I have been following this tutoreal https://youtu.be/0iB5IPoTDts?si=IITBu1CNXT2zwTCP&t=3679 (i included the timestamp) Dockerfile Docker-compose returned the following error: i tried adding various suggested .dockerignore files but nothing worked. Has anyone had the same issue and solved it without downgrading docker desktop to 4.22 EDIT: running docker-compose up from WSL clearly identified the cause of the error: |
How can I downgrade docker version? |
How did you downgraded docker version? |
While you may have to uninstall your current version, I downloaded older versions from https://docs.docker.com/desktop/release-notes/ |
I have a volume inside my project root directory. What worked for me in Docker Desktop version 4.27.2 is adding the volume directory to the |
Description
Cannot run docker compose with building images (but I also have similar project that works fine).
Definition in docker-compose.yml:
Of course this is simplified definition, but there is nothing abnormal. Dockerfile contains several multistage instructions.
I'm not touching any key :)
Output:
Self-diagnose tool does not found any errors
Reproduce
docker compose up --build
Expected behavior
Docker should build and start normally
docker version
Client: Cloud integration: v1.0.35+desktop.5 Version: 24.0.6 API version: 1.43 Go version: go1.20.7 Git commit: ed223bc Built: Mon Sep 4 12:32:48 2023 OS/Arch: windows/amd64 Context: default Server: Docker Desktop 4.25.2 (129061) Engine: Version: 24.0.6 API version: 1.43 (minimum version 1.12) Go version: go1.20.7 Git commit: 1a79695 Built: Mon Sep 4 12:32:16 2023 OS/Arch: linux/amd64 Experimental: false containerd: Version: 1.6.22 GitCommit: 8165feabfdfe38c65b599c4993d227328c231fca runc: Version: 1.1.8 GitCommit: v1.1.8-0-g82f18fe docker-init: Version: 0.19.0 GitCommit: de40ad0
docker info
Diagnostics ID
72930303-7115-4BA1-91B9-A784121E78E8/20231128113933
Additional Info
Windows 11,
Docker desktop v4.25.2
The text was updated successfully, but these errors were encountered: