-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Labels
Description
Contributing guidelines and issue reporting guide
- I've read the contributing guidelines and wholeheartedly agree. I've also read the issue reporting guide.
Well-formed report checklist
- I have found a bug that the documentation does not mention anything about my problem
- I have found a bug that there are no open or closed issues that are related to my problem
- I have provided version/information about my environment and done my best to provide a reproducer
Bug description
ADD for Git repo fails on Windows when buildx/BuildKit is used.
Reproduction
Use a Windows machine (Windows 11 in my case, but specific version is not important, you might just need to adjust base image version).
Set up dockerd using your preferred way.
Create an empty directory.
Place a Dockerfile in it:
FROM mcr.microsoft.com/windows/nanoserver:ltsc2022
ADD https://github.com/moby/moby.git C:\\mobyRun docker buildx build .
Expected: build succeeds
Actual:
$ docker buildx build .
[+] Building 16.9s (6/6) FINISHED docker:default
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 135B 0.0s
=> [internal] load metadata for mcr.microsoft.com/windows/nanoserver:ltsc2022 0.8s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 139B 0.0s
=> [1/2] FROM mcr.microsoft.com/windows/nanoserver:ltsc2022@sha256:60612a30303eb5a15ce7f53fa2eecf70bca41d72657de0482fbde601ae5f3403 15.8s
=> => resolve mcr.microsoft.com/windows/nanoserver:ltsc2022@sha256:60612a30303eb5a15ce7f53fa2eecf70bca41d72657de0482fbde601ae5f3403 0.0s
=> => sha256:c8c762a2c2783d40d4a09719516adec866b153c94682ef9c4c672227f2f21573 122.71MB / 122.71MB 4.5s
=> => extracting sha256:c8c762a2c2783d40d4a09719516adec866b153c94682ef9c4c672227f2f21573 11.2s
=> ERROR [2/2] ADD https://github.com/moby/moby.git C:/moby 15.9s
=> CANCELED [2/2] ADD https://github.com/moby/moby.git C:/moby 0.0s
------
> [2/2] ADD https://github.com/moby/moby.git C:/moby:
1.037 ref: refs/heads/master HEAD
1.037 a52171f5eeb6e553e7c4744abf6b722962b2aca4 HEAD
2.080 a52171f5eeb6e553e7c4744abf6b722962b2aca4 refs/heads/master
3.237 ref: refs/heads/master HEAD
3.237 a52171f5eeb6e553e7c4744abf6b722962b2aca4 HEAD
4.149 a52171f5eeb6e553e7c4744abf6b722962b2aca4
15.09 fatal: unable to access '\\.\GLOBALROOT\Device\Null/.config/git/config': Invalid argument
15.10 /mingw64/libexec/git-core/git-sh-setup: line 46: /git-sh-i18n: No such file or directory
------
ERROR: failed to build: failed to solve: failed to update submodules for https://github.com/moby/moby.git: git stderr:
fatal: unable to access '\\.\GLOBALROOT\Device\Null/.config/git/config': Invalid argument
/mingw64/libexec/git-core/git-sh-setup: line 46: /git-sh-i18n: No such file or directory
: exit status 1
Version information
Reproes with moby 28.5.1. Also reproes with today latest master branch (commit a52171f5eeb6e553e7c4744abf6b722962b2aca4).
I believe this can also be reproduced by using buildctl + buildkitd without moby.
Debugging shows that it fails when checking out submodules.
Reactions are currently unavailable