You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been doing some testing with windows container builds recently.
I have been trying to figure out it cache/bind mounts are supposed to work or not.
I have found this issue: #4837 Maybe the underlaying cause is the same even though the error message is different?
Environment
Windows Server 2022
Builkit 0.18.1
Containerd 1.7.24
Dockerfile
FROM mcr.microsoft.com/windows/nanoserver:ltsc2022
USER ContainerAdministrator
WORKDIR C:/BUILD/
RUN --mount=type=cache,target=C:/BUILD/ echo "Hello" >> hello.txt
Output
buildx build --progress=plain .
#0 building with "windows" instance using remote driver
#1 [internal] load build definition from Dockerfile
#1 transferring dockerfile: 208B done
#1 DONE 0.1s
#2 [internal] load metadata for mcr.microsoft.com/windows/nanoserver:ltsc2022
#2 DONE 0.1s
#3 [internal] load .dockerignore
#3 transferring context:
#3 transferring context: 2B done
#3 DONE 1.2s
#4 [stage-0 1/3] FROM mcr.microsoft.com/windows/nanoserver:ltsc2022@sha256:eb59dfa1056e41b65cb12b679280e29f10d64e2b569b877710e227a77fef223f
#4 resolve mcr.microsoft.com/windows/nanoserver:ltsc2022@sha256:eb59dfa1056e41b65cb12b679280e29f10d64e2b569b877710e227a77fef223f 0.0s done
#4 DONE 0.0s
#5 [stage-0 2/3] WORKDIR C:/TEMP/
#5 CACHED
#6 [stage-0 3/3] RUN --mount=type=cache,target=C:/TEMP/ echo "Hello" >> hello.txt
#6 ERROR: process "cmd /S /C echo \"Hello\" >> hello.txt" did not complete successfully: failed to create shim task: invalid OCI spec - Type 'windows-layer' not supported: unknown
------
> [stage-0 3/3] RUN --mount=type=cache,target=C:/TEMP/ echo "Hello" >> hello.txt:
------
WARNING: No output specified with remote driver. Build result will only remain in the build cache. To push result image into registry use --push or to load image into docker use --load
Dockerfile:7
--------------------
5 | WORKDIR C:/TEMP/
6 |
7 | >>> RUN --mount=type=cache,target=C:/TEMP/ echo "Hello" >> hello.txt
--------------------
ERROR: failed to solve: process "cmd /S /C echo \"Hello\" >> hello.txt" did not complete successfully: failed to create shim task: invalid OCI spec - Type 'windows-layer' not supported: unknown
Is this the expected result or have I possibly done something wrong?
The text was updated successfully, but these errors were encountered:
I have been doing some testing with windows container builds recently.
I have been trying to figure out it cache/bind mounts are supposed to work or not.
I have found this issue: #4837 Maybe the underlaying cause is the same even though the error message is different?
Environment
Windows Server 2022
Builkit 0.18.1
Containerd 1.7.24
Dockerfile
Output
Is this the expected result or have I possibly done something wrong?
The text was updated successfully, but these errors were encountered: