(一)docker之linux安装

1.在 Linux 机器上打开一个新的 Shell。

2. 使用wget从 https://get.docker.com 获取并运行 Docker 安装脚本,然后采用 Shell 中管道(pipe)的方式来执行这个脚本。

$ wget -qO- https://get.docker.com/ | sh

modprobe: FATAL: Module aufs not found /lib/modules/4.4.0-36-generic
+ sh -c 'sleep 3; yum -y -q install docker-engine'
<Snip>
If you would like to use Docker as a non-root user, you should
now consider adding your user to the "docker" group with
something like:

sudo usermod -aG docker your-user

Remember that you will have to log out and back in...

3. 最好通过非 root 用户来使用 Docker。这时需要添加非 root 用户到本地 Docker Unix 组当中。

$ sudo usermod -aG docker docker_01

$ cat /etc/group | grep docker
docker:x:999:docker_01

4.确认 Docker 已经在 Linux 上安装成功。

$ docker --version
Docker version 18.01.0-ce, build 03596f5
$ docker system info
Containers: 0
Running: 0
Paused: 0
Stopped: 0
Images: 0
Server Version: 18.01.0-ce
Storage Driver: overlay2
Backing Filesystem: extfs
<Snip>

提示:如果上述步骤在自己的 Linux 发行版中无法成功执行,可以访问 Docker Docs 网站(https://docs.docker.com)并单击与自己的版本相关的那个链接。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值