【发布时间】:2021-04-12 09:23:28
【问题描述】:
使用docker hub api获取docker镜像的标签:
curl -sL https://hub.docker.com/v2/repositories/<org>/<name>/tags
我将它输入| jq 并提取我需要的内容。
但是有些图像没有组织,例如mariadb.
这些我都试过了:
curl -sL https://hub.docker.com/v2/repositories/mariadb/tags
curl -sL https://hub.docker.com/v2/repositories/_/mariadb/tags
curl -sL https://hub.docker.com/v2/repositories/mariadb/_/tags
curl -sL https://hub.docker.com/v2/repositories/mariadb/mariadb/tags
但是那些给出错误,或者这个:
{"count":0,"next":null,"previous":null,"results":[]}
我该怎么做?
【问题讨论】:
标签: docker docker-registry dockerhub