这是docker info
的信息,显示已经成功配置代理
Client:
Context: default
Debug Mode: false
Plugins:
app: Docker App (Docker Inc., v0.9.1-beta3)
buildx: Build with BuildKit (Docker Inc., v0.5.1-docker)
scan: Docker Scan (Docker Inc., v0.5.0)
Server:
Containers: 0
Running: 0
Paused: 0
Stopped: 0
Images: 11
Server Version: 20.10.2
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Cgroup Version: 1
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: io.containerd.runc.v2 io.containerd.runtime.v1.linux runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 269548fa27e0089a8b8278fc4fc781d7f65a939b
runc version: ff819c7e9184c13b7c2607fe6c30ae19403a7aff
init version: de40ad0
Security Options:
seccomp
Profile: default
Kernel Version: 4.19.121-linuxkit
Operating System: Docker Desktop
OSType: linux
Architecture: x86_64
CPUs: 6
Total Memory: 1.943GiB
Name: docker-desktop
ID: UK4R:F7XM:5M62:K77P:XLYE:7CBH:OLAV:7RNG:55E6:BDDO:62SF:QB2I
Docker Root Dir: /var/lib/docker
Debug Mode: false
HTTP Proxy: gateway.docker.internal:3128
HTTPS Proxy: gateway.docker.internal:3129
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Registry Mirrors:
https://bnj5sh4t.mirror.aliyuncs.com/
https://docker.mirrors.ustc.edu.cn/
https://hub-mirror.c.163.com/
Live Restore Enabled: false
按照网上的说法,我也在图形化界面中配置了国内代理,如下图所示,但是在docker pull
的时候,docker 默认还是从国外的https://registry-1.docker.io/v2/
拉取镜像。只有 mac 版本存在这个问题,linux 配了一下 daemon.json 就好了,但我不太想每次开 docker 还得启动虚拟机,所以想问下大家有碰到过这种情况吗?怎么解决呢?
1
learningman 2021-02-16 14:13:11 +08:00 via Android
有没有可能是这个镜像还没有同步,所以重定向到了原来的源?
pull 个 Ubuntu 试试 |
2
InternetExplorer 2021-02-16 14:15:02 +08:00 via iPhone
只有常用的镜像会同步吧,全同步这数据量也太大了
|
3
sakai OP @learningman docker pull ubuntu 的时候也是如此
|
4
sakai OP @InternetExplorer 同一个 docker 镜像,在 linux 下确实就是走的国内代理,可见国内确实同步了,所以应该是 mac 版 docker 的问题。我试了用 docker for mac 来 pull ubuntu,也是一样走国外了
|
5
ydsq 2021-05-21 09:24:24 +08:00
碰到同样的问题,楼主怎么解决的?
|
6
JQ 2022-05-26 10:27:59 +08:00
同样的问题
|
7
ply 49 天前
同样的问题
|