记录下国内机安装Docker的全流程
Docker 官方一键安装脚本,从阿里源安装curl -fsSL https://get.docker.com | bash -s docker --mirror Aliyun
设置开机自启
systemctl enable docker
启动Docker
systemctl start docker
一键安装最新版 Docker Compose:
curl -L https://get.daocloud.io/docker/compose/releases/download/v2.4.1/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
配置镜像源
mkdir -p /etc/docker
tee /etc/docker/daemon.json <<-'EOF'
{
"registry-mirrors": [
"https://docker.naixi.net",
"https://docker-2.naixi.net"
]
}
EOF
重启服务
systemctl daemon-reload
systemctl restart docker
查看是否生效
docker info 感謝大佬,,, 頂一下...{:5_150:}
页:
[1]