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'm writing this issue because one of the registry behaviors is not implemented yet. It's not the most common use-case but I wonder if it's planned to be implemented soon or not?
When docker pushes an image, each layer will be uploaded if this is the first time this layer/blob is sent to the registry. But when an image has shared layers that have already been pushed to an A repository and then a new image on another B repository is pushed, docker will try to mount the layer from the A repository to B avoiding re-uploading.
Docker client will send this query to mount a layer from image-A to the new image-B with the common blob ID to mount: POST /v2/image-B/blobs/uploads/?from=image-A&mount=sha256%3A6b17377d415bc5e55a5a71a28a74139961b94b9f835c9c29852e7658d76c2ab0
The registry should respond with 201 Created if the mount is successful otherwise it will return 202 Accepted to re-upload the layer
Currently the serverless-registry (in a wrangler dev environment) reply with 202 and docker will upload again the layer (wich work with docker push command).
Some client command (like docker manifest push) doesn't handle when the blob mounting doesn't work and crash with the message error mounting image-a@sha256:6b17377d415bc5e55a5a71a28a74139961b94b9f835c9c29852e7658d76c2ab0 to localhost:8787/image-b:test
The text was updated successfully, but these errors were encountered:
I can try to submit a PR for this use case, but I'm wondering which method would be best suited to duplicate an object in R2? I've read the Worker R2 API documentation but nothing about the duplication operation. Is there any official support coming soon?
If we were to use the S3 API, the layers could be >5Gb and only CopyObject seems to support the x-amz-copy-source header and not UploadPartCopy for larger files...
Hello,
First of all, thank you very much for this tool!
I'm writing this issue because one of the registry behaviors is not implemented yet. It's not the most common use-case but I wonder if it's planned to be implemented soon or not?
When docker pushes an image, each layer will be uploaded if this is the first time this layer/blob is sent to the registry. But when an image has shared layers that have already been pushed to an
A
repository and then a new image on anotherB
repository is pushed, docker will try tomount
the layer from theA
repository toB
avoiding re-uploading.This behavior is described in the
Cross Repository Blob Mount
section below: https://docker-docs.uclv.cu/registry/spec/api/#pushing-an-imageimage-A
to the newimage-B
with the common blob ID to mount:POST /v2/image-B/blobs/uploads/?from=image-A&mount=sha256%3A6b17377d415bc5e55a5a71a28a74139961b94b9f835c9c29852e7658d76c2ab0
201 Created
if the mount is successful otherwise it will return202 Accepted
to re-upload the layer202
and docker will upload again the layer (wich work withdocker push
command).docker manifest push
) doesn't handle when the blob mounting doesn't work and crash with the messageerror mounting image-a@sha256:6b17377d415bc5e55a5a71a28a74139961b94b9f835c9c29852e7658d76c2ab0 to localhost:8787/image-b:test
The text was updated successfully, but these errors were encountered: