docker: Error response from daemon: Get https://registry-1.docker.io/v2/: Service Unavailable. IN DOCKER , MAC

前端 未结 19 1442
北海茫月
北海茫月 2021-02-01 02:53

I am having this issue in my Mac system 10.11.6

system3:postgres saurabh-gupta2$ docker build -t postgres .
Sending build context to Docker daemon  38.91kB
Step          


        
相关标签:
19条回答
  • 2021-02-01 03:20

    try to reload daemon then restart docker service.

    systemctl daemon-reload
    
    0 讨论(0)
  • 2021-02-01 03:20

    I had this issue when I first installed Docker and ran

    docker run hello-world
    

    I was on a corporate network and switching to my personal network solved the issue for me.

    0 讨论(0)
  • 2021-02-01 03:21

    I tried running on Windows, and got this problem after an update. I tried restarting the docker service as well as my pc, but nothing worked.

    When running:

    curl https://registry-1.docker.io/v2/ && echo Works
    

    I got back:

    {"errors":[{"code":"UNAUTHORIZED","message":"authentication required","detail":null}]}
    Works
    

    Eventually, I tried: https://github.com/moby/moby/issues/22635#issuecomment-284956961

    By changing the fixed address to 8.8.8.8:

    Which worked for me! I still got the unauthorized message for curl https://registry-1.docker.io/v2/ but I managed to pull images from docker hub.

    0 讨论(0)
  • 2021-02-01 03:21

    One option which worked for me on MAC.

    Click on the Docker Icon in the tray. Open Preferences -> Proxies. Click on Manual Proxy and specify Web Server (HTTP) proxy and Secure Web server (HTTPS) proxy in the same format as we specify in HTTPS_PROXY env variable. Choose Apply and Restart.

    This Worked for me

    0 讨论(0)
  • 2021-02-01 03:22

    I had the following entries in my /etc/hosts file:

    34.228.211.243  registry-1.docker.io
    34.205.88.205   auth.docker.io
    104.18.121.25   production.cloudflare.docker.com
    

    Just by commenting them out, I fixed the problem.

    0 讨论(0)
  • 2021-02-01 03:25
    docker logout
    docker login
    

    This might solve your problem

    0 讨论(0)
提交回复
热议问题