How to get a list of images on docker registry v2

前端 未结 16 1764
孤城傲影
孤城傲影 2020-12-02 04:04

I\'m using docker registry v1 and I\'m interested in migrating to the newer version, v2. But I need some way to get a list of images present on registry; for example with re

16条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-02 04:15

    Docker search registry v2 functionality is currently not supported at the time of this writing. See discussion since Feb 2015: "propose registry search functionality #206" https://github.com/docker/distribution/issues/206

    I wrote a script, view-private-registry, that you can find: https://github.com/BradleyA/Search-docker-registry-v2-script.1.0 It is not pretty but it gets the information needed from the private registry.

    Example of output from view-private-registry:

    $ view-private-registry`
    busybox:latest
    gcr.io/google_containers/etcd:2.0.9
    gcr.io/google_containers/hyperkube:v0.21.2
    gcr.io/google_containers/pause:0.8.0
    google/cadvisor:latest
    jenkins:latest
    logstash:latest
    mongo:latest
    nginx:latest
    python:2.7
    redis:latest
    registry:2.1.1
    stackengine/controller:latest
    tomcat:7
    tomcat:latest
    ubuntu:14.04.2
    Number of images:   16
    Disk space used:    1.7G    /mnt/three/docker-registry/registry-data
    

提交回复
热议问题