Skip to content
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

[Bug]: Zot Registry does not serve images with a full image name in org.opencontainers.image.ref.name #2860

Open
ChristianWolf2 opened this issue Jan 3, 2025 · 3 comments
Labels
awaiting-feedback bug Something isn't working rm-external Roadmap item submitted by non-maintainers

Comments

@ChristianWolf2
Copy link

zot version

v2.1.0

Describe the bug

Zot does not serve OCI images created with docker OCI exporter. Instead it answers with a 404 response.

The reason is that docker writes the full image name with the tag in the org.opencontainers.image.ref.name annotation in the index.json file. But according to the OCI spec this is actually allowed: https://github.com/opencontainers/image-spec/blob/5325ec48851022d6ded604199a3566254e72842a/annotations.md#:~:text=org.opencontainers.image.ref.name

See also my initial bug raised against buildkit: moby/buildkit#4615

To reproduce

  1. Build some docker image with OCI exporter: https://docs.docker.com/build/exporters/oci-docker/
    docker buildx build . --output="type=oci,tar=false,dest=/tmp/registry/foo,name=bar"
  2. Start zot registry with /tmp/registry as root
  3. Try to pull image foo:bar from registry

Expected behavior

Zot can serve images with a full image name in the org.opencontainers.image.ref.name annotation, instead of just the tag.

Screenshots

No response

Additional context

No response

@ChristianWolf2 ChristianWolf2 added the bug Something isn't working label Jan 3, 2025
@rchincha rchincha added the rm-external Roadmap item submitted by non-maintainers label Jan 3, 2025
@rchincha
Copy link
Contributor

rchincha commented Jan 3, 2025

@ChristianWolf2

I can skopeo copy an image from one path to another. Does the ref.name get updated accordingly? Alternatively, just because ref.name is set a certain way, does it impose restrictions on where it can be pushed?

@ChristianWolf2
Copy link
Author

Copying these images with skopeo works, but that is not my use case.

My use case is that I export images with the docker oci exporter to a certain file directory, and have a zot registry running which uses this file directory to serve images.

As I understood zot, this is one of the main features:

  • Uses OCI image layout for image storage
  • Can serve any OCI image layout as a registry

@andaaron
Copy link
Contributor

andaaron commented Jan 6, 2025

Hi @ChristianWolf2, I posted a comment at moby/buildkit#4615 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting-feedback bug Something isn't working rm-external Roadmap item submitted by non-maintainers
Projects
None yet
Development

No branches or pull requests

3 participants