CentOS下Docker安装流程

在安装的CentOS系统中,按如下步骤安装docker:

1.系统更新,输入命令:yum update

2.安装yum-utils,输入命令:yum install -y yum-utils

3.设置docker repo,输入命令:yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

4.安装docker,输入命令:yum install docker-ce docker-ce-cli containerd.io,如需安装特定版本,请输入命令:yum install docker-ce-<VERSION_STRING> docker-ce-cli-<VERSION_STRING> containerd.io

5.启用docker,输入命令:systemctl start docker

 安装过程中,可能出现如下问题:

Problem: package docker-ce-3:19.03.7-3.el7.x86_64 requires containerd.io >= 1.2.2-3, but none of the providers can be installed

解决方案:

wget https://download.docker.com/linux/centos/7/x86_64/stable/Packages/containerd.io-1.2.13-3.1.el7.x86_64.rpm
yum -y install ./containerd.io-1.2.13-3.1.el7.x86_64.rpm

https://download.docker.com/linux/centos/7/x86_64/stable/Packages/ ,手动下载最新版本安装即可。

其它细节参考:https://docs.docker.com/engine/install/centos/

posted @ 2020-04-14 19:38  从零开始-DotNET技术  阅读(262)  评论(0编辑  收藏  举报