centos7安装docker

  1. 安装数据存储驱动包

    shell 复制代码
    yum install -y yum-utils device-mapper-persistent-data lvm2
  2. 添加阿里安装源

    shell 复制代码
    yum-config-manager --add-repo http://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo
  3. 自动检测哪个安装源快

    shell 复制代码
    yum makecache fast
  4. 安装docker服务(服务器和客户端都会安装)

    shell 复制代码
    yum -y install docker-ce
  5. 启动docker服务

    shell 复制代码
    service docker start
  6. 查看docker版本

    shell 复制代码
    docker version
  7. 拉取hello-world镜像

    shell 复制代码
    docker pull hello-world
  8. 启动hello-world容器

    shell 复制代码
    docker run hello-world
相关推荐
zhenshanrenhao2 小时前
#买硬盘欲安装k8s记
云原生·容器·kubernetes
HWL56792 小时前
“preinstall“: “npx only-allow pnpm“
运维·服务器·前端·javascript·vue.js
门前灯3 小时前
Linux系统之iprconfig 命令详解
linux·运维·服务器·iprconfig
tb_first3 小时前
k8sday09
linux·云原生·容器·kubernetes
忧郁的橙子.4 小时前
三、k8s 1.29 之 安装2
linux·运维·服务器
huangyuchi.4 小时前
【Linux系统】动静态库的制作
linux·运维·服务器·动态库·静态库·库的简单制作
闻不多4 小时前
用llamaindex搭建GAR遇到400
android·运维·服务器
jim写博客5 小时前
Linux进程概念(四)环境地址变量
linux·运维·服务器
是小崔啊5 小时前
【Jenkins】01 - Jenkins安装
运维·jenkins
Nie_Xun5 小时前
ubuntu网络共享
linux·运维·ubuntu