Centos安装配置Docker

Centos安装配置Docker

  1. 依赖安装
    sudo yum -y install yum-utils device-mapper-persistent-data lvm2
    
  2. 添加依赖源
    sudo yum-config-manager --add-repo http://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo
    
  3. 安装docker
    sudo yum install -y docker-ce
    
  4. 启动docker
    sudo systemctl start docker
    
  5. 设置为开机启动
    systemctl enable docker
    

你可能感兴趣的:(DevOps,docker,centos,linux)