安装命令

sudo yum install -y yum-utils device-mapper-persistent-data lvm2
sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
sudo yum install docker-ce docker-ce-cli containerd.io
sudo systemctl start docker
sudo systemctl enable docker

设置registry-mirrors

vim /etc/docker/daemon.json,添加以下内容:

{
    "registry-mirrors": [
        "https://xxx.mirror.xxx.com"
    ]
}

重启服务

sudo systemctl daemon-reload
sudo systemctl restart docker

标签: centos, docker

添加新评论