我正在尝试在 MAC 上安装 Docker。我遇到了以下问题
predix-docker xxxxxx $ docker pull nginx
Using default tag: latest
latest: Pulling from library/nginx
968c69f18673: Pulling fs layer
963493e54e68: Layer already being pulled by another client. Waiting.
755b4eb93a9e: Layer already being pulled by another client. Waiting.
f3b2532b0301: Layer already being pulled by another client. Waiting.
f3bf4daa2ff2: Layer already being pulled by another client. Waiting.
6685b2154893: Layer already being pulled by another client. Waiting.
a2295636c7aa: Already exists
3035387b9e83: Already exists
Pulling repository docker.io/library/nginx
Tag latest not found in repository docker.io/library/nginx
当我检查 Docker 镜像时,我找不到 nginx repo。请帮忙如何下载。
答案1
这是您这边的本地问题:
$ docker pull nginx
Using default tag: latest
Trying to pull repository docker.io/library/nginx ...
latest: Pulling from docker.io/library/nginx
51f5c6a04d83: Already exists
a3ed95caeb02: Pull complete
51d229e136d0: Pull complete
bcd41daec8cc: Pull complete
Digest: sha256:0fe6413f3e30fcc5920bc8fa769280975b10b1c26721de956e1428b9e2f29d04
Status: Downloaded newer image for docker.io/nginx:latest
尝试移除图像(docker rmi nginx
)并再次拉取它。
此外,看起来您正在运行并发拉取。
答案2
看起来 Docker 处理网络错误的方式是错误的。例如,DNS 超时可能会报告为“未找到标签 xxx”。这就是错误可能间歇性出现的原因。我见过几次这种情况,将 DNS 服务器更改为 google DNS (8.8.8.8) 并等待几分钟,就修复了这个 docker 错误。