Docker入门系列-----Docker的安装


  1. 安装依赖包
    yum install -y yum-utils device-mapper-persistent-data lvm2
  2. 添加Docker软件包源
    yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
  3. 安装Docker CE
    yum install -y docker-ce
  4. 启动Docker服务并设置开机启动
    systemctl start docker
    systemctl enable docker