--------------------------------------------(建议直接看解决方案部分) --------------------------------------------
问题描述
按照官网安装完Docker,在最后一步检验docker是否安装成功,即运行sudo docker run hello-world这条命令时一直一直一直出现以下问题:
Unable to find image 'hello-world:latest' locally
latest: Pulling from library/hello-world
c1ec31eb5944: Retrying in 1 second
docker: error pulling image configuration: download failed after attempts=6: dial tcp 162.125.82.7:443: connect: connection refused.
See 'docker run --help'.
如下图:
然后尝试了很多种方法,例如:
方法一: