解決docker:pull access denied for hello-wrold, repository does not exist or may require 'docker login'.

在win 10上安裝好Docker后,根據(jù)官方文檔示例運(yùn)行命令:docker run hello-world,報(bào)錯(cuò):

C:\Users\stein>docker run hello-wrold
Unable to find image 'hello-wrold:latest' locally
docker: Error response from daemon: pull access denied for hello-wrold, repository does not exist or may require 'docker login'.

根據(jù)錯(cuò)誤提示是:repository不存在或者需要運(yùn)行docker login登錄,但是根據(jù)官方文檔:在docker hub中搜索或者拉去images時(shí)并不需要賬戶并且登錄,如圖1:

圖1

于是,轉(zhuǎn)而去配置repository,事實(shí)發(fā)現(xiàn)并沒有卵用,只好google之,在Stackoverflow上的這個(gè)回答Docker hello-world: authentication error中可以找到一些線索:

圖2

根據(jù)圖2來看,還是需要使用賬號和密碼去登錄的,不然也不會有那么多人問這個(gè)相關(guān)的問題;

于是乖乖的去創(chuàng)建Docker id,然后在運(yùn)行docker run hello-world命令之前先使用命令docker login登錄,過程如下:

 C:\Users\stein>docker login
Login with your Docker ID to push and pull images from Docker Hub. If you don't have a Docker ID, head over to [https://hub.docker.com](https://hub.docker.com/) to create one.
Username: daoyi
Password:
Login Succeeded

C:\Users\stein>docker run hello-world
Unable to find image 'hello-world:latest' locally
latest: Pulling from library/hello-world
ca4f61b1923c: Pull complete
Digest: sha256:66ef312bbac49c39a89aa9bcc3cb4f3c9e7de3788c944158df3ee0176d32b751
Status: Downloaded newer image for hello-world:latest
Hello from Docker!
This message shows that your installation appears to be working correctly.
To generate this message, Docker took the following steps:
1\. The Docker client contacted the Docker daemon.
2\. The Docker daemon pulled the "hello-world" image from the Docker Hub.
    (amd64)
3\. The Docker daemon created a new container from that image which runs the
    executable that produces the output you are currently reading.
4\. The Docker daemon streamed that output to the Docker client, which sent it
    to your terminal.
To try something more ambitious, you can run an Ubuntu container with:
$ docker run -it ubuntu bash
Share images, automate workflows, and more with a free Docker ID:
[https://cloud.docker.com/](https://cloud.docker.com/)
For more examples and ideas, visit:
[https://docs.docker.com/engine/userguide/](https://docs.docker.com/engine/userguide/)
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

  • Spring Cloud為開發(fā)人員提供了快速構(gòu)建分布式系統(tǒng)中一些常見模式的工具(例如配置管理,服務(wù)發(fā)現(xiàn),斷路器,智...
    卡卡羅2017閱讀 136,569評論 19 139
  • 最近研究了幾天docker的快速部署,感覺很有新意,非常輕量級和方便,打算在公司推廣一下,解放運(yùn)維,省得每次部署一...
    Helen_Cat閱讀 1,569評論 0 4
  • Q:按揭未還清的房子能否轉(zhuǎn)手出售? A:不能 P:如果房產(chǎn)證出來了,所有的問題都好解決。房產(chǎn)證下來了,可以先掛牌到...
    戰(zhàn)敭閱讀 214評論 0 0
  • Some days I barely hold on 有時(shí),眼前的生活將我一點(diǎn)點(diǎn)拖垮When life drags...
    陳嘉育閱讀 708評論 1 1
  • 比薩雖屬面包的一個(gè)分支,但其作為主食的優(yōu)越性使其逐漸成為一大品類,在中國的餐飲市場上獨(dú)樹一幟深受消費(fèi)者喜愛。比薩在...
    xiaoke87fish閱讀 451評論 0 0

友情鏈接更多精彩內(nèi)容