Docker之docker镜像加速配置

一 获取加速地址

  • 科大镜像:https://docker.mirrors.ustc.edu.cn/
  • 网易:https://hub-mirror.c.163.com/
  • 阿里云:https://cr.console.aliyun.com/
  • 七牛云加速器:https://reg-mirror.qiniu.com
  • 腾讯云:https://mirrors.css.tencentyun.com

二 生成配置文件

root@ubuntu:~# cat /etc/docker/daemon.json
{
        "registry-mirrors":["https://fv50tv30.mirror.aliyuncs.com","https://reg-mirror.qiniu.com"],
        "dns":["114.114.114.114","8.8.8.8"]

}

三 重启docker服务

点击查看代码
root@ubuntu:~# systemctl restart docker

四 验证结果

点击查看代码
root@ubuntu:~# 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.6.3-docker)
  scan: Docker Scan (Docker Inc., v0.9.0)

Server:
Containers: 5
Running: 0
Paused: 0
Stopped: 5
Images: 2
Server Version: 19.03.15
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
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: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 5b46e404f6b9f661a205e28d59c982d3634148f8
runc version: v1.0.2-0-g52b36a2
init version: fec3683
Security Options:
apparmor
seccomp
Profile: default
Kernel Version: 4.15.0-161-generic
Operating System: Ubuntu 18.04.5 LTS
OSType: linux
Architecture: x86_64
CPUs: 1
Total Memory: 920.6MiB
Name: ubuntu
ID: C7OW:36ZY:23TD:WZPR:ILLI:MFXS:I3WJ:6I7Q:U7DX:OMOC:ITUR:XSG4
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Registry Mirrors:
https://fv50tv30.mirror.aliyuncs.com/
https://reg-mirror.qiniu.com/
Live Restore Enabled: false

 

上一篇:fluent计算结果进行镜像显示


下一篇:Windows平台快速搭建minikube环境-20分钟