背景:
官方镜像站下载速度慢,推荐使用阿里云镜像站,加速镜像下载速度
操作步骤
阿里云官网链接:阿里云docker加速器
1.阿里云镜像加速器地址:https://jwrmyfx1.mirror.aliyuncs.com
2.服务器内配置
2.1 centos
sudo mkdir -p /etc/docker
sudo tee /etc/docker/daemon.json <<-'EOF'
{
"registry-mirrors": ["https://jwrmyfx1.mirror.aliyuncs.com"]
}
EOF
sudo systemctl daemon-reload
sudo systemctl restart docker
2.2 Ubuntu
sudo mkdir -p /etc/docker
sudo tee /etc/docker/daemon.json <<-'EOF'
{
"registry-mirrors": ["https://jwrmyfx1.mirror.aliyuncs.com"]
}
EOF
sudo systemctl daemon-reload
sudo systemctl restart docker