Docker 镜像加速使用教程

为了加速镜像拉取,使用以下命令设置 registry mirror

支持系统:Ubuntu 16.04+、Debian 8+、CentOS 7+

加速域名:https://docker.zhkugh.top

  1. 修改 Registry Mirrors 地址为我们的加速域名:
    #vim /etc/docker/daemon.json
      {
        "registry-mirrors": ["https://docker.zhkugh.top"]
      }
  2. 重启 Docker 服务:
    sudo systemctl restart docker
  3. 通过加速域名拉取镜像:
    docker pull docker.zhkugh.top/library/alpine:latest
      docker pull docker.zhkugh.top/coredns/coredns:latest
      docker pull docker.zhkugh.top/library/mysql:8.0
  4. 拉取镜像测试:
    Image