Skip to content

Wrong latest image tag for selfhosted repositories #162

Open
@ailowry

Description

@ailowry

I am running version-checker in an offline environment that uses a caching proxy to access Dockerhub. In this case I am looking up the standard redis image and it is showing the wrong latest tag.

version-checker

I think this is happening because this path is used in selfhosted.go:
tagsPath = "%s/v2/%s/tags/list?n=500"

OCI distribution specification indicates that the n parameter will return the first n tags. The last parameter can be added for additional filtering.
https://github.com/opencontainers/distribution-spec/blob/main/spec.md#listing-tags
Without the last query parameter (described next), the list returned will start at the beginning of the list and include <int> results. As above, the tags MUST be in lexical order.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingimage-accuracyUsed to track bugs that are related to image accuracy

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions