Featured image of post Docker

Docker

Docker Registry Mirror

/etc/docker/daemon.json

1
2
3
4
5
{
  "registry-mirrors": [
    "https://example.com"
  ]
}

记得 sudo systemctl reload docker.service 重载服务

Docker CE Mirror

Ubuntu

清华大学开源软件镜像站 - Docker CE 软件仓库

1
2
3
4
echo \
  "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://mirrors.tuna.tsinghua.edu.cn/docker-ce/linux/ubuntu \
  $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
  sudo tee /etc/apt/sources.list.d/docker.list > /dev/null

/etc/apt/sources.list.d/docker.list

1
deb [arch=amd64 signed-by=/etc/apt/keyrings/docker.asc] https://mirrors.tuna.tsinghua.edu.cn/docker-ce/linux/ubuntu   jammy stable
Licensed under CC BY-NC-SA 4.0