docker-registry-util icon indicating copy to clipboard operation
docker-registry-util copied to clipboard

Pagination is unsupported

Open nathforge opened this issue 6 years ago • 0 comments

Repository and tag lists can be paginated:

  • https://docs.docker.com/registry/spec/api/#pagination
  • https://docs.docker.com/registry/spec/api/#pagination-1

requests exposes this via response.links, e.g:

url = "https://myregistry/v2/_catalog"
while True:
    response = self.get(url)
    print(response.url)
    if "next" in response.links:
        url = urllib.parse.urljoin(response.url, response.links["next"]["url"])
    else:
        break

nathforge avatar Apr 16 '18 14:04 nathforge