Deepin15.11安装最新版本Docker
移除之前安装的docker
sudo apt-get remove docker.io docker-engine
安装密钥管理与下载相关的工具
sudo apt-get install apt-transport-https ca-certificates curl gnupg2 software-properties-common
下载并安装密钥
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add -
查看密钥是否安装成功
sudo apt-key fingerprint 0EBFCD88
在 source.list 中添加 docker-ce 软件源
【Deepin15.11安装最新版本Docker】sudo add-apt-repository "deb [arch=amd64] https://mirrors.ustc.edu.cn/docker-ce/linux/debian wheezy stable"
运行上面命令若报如下错误(15.11)
Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 95, in
sp = SoftwareProperties(options=options)
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 109, in __init__
self.reload_sourceslist()
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 599, in reload_sourceslist
self.distro.get_sources(self.sourceslist)
File "/usr/lib/python3/dist-packages/aptsources/distro.py", line 93, in get_sources
(self.id, self.codename))
aptsources.distro.NoDistroTemplateException: Error: could not find a distribution template for Deepin/stable
则编辑(sudo vim /etc/apt/sources.list) 添加一行即可,原因未知
deb [arch=amd64] https://mirrors.ustc.edu.cn/docker-ce/linux/debian stretch stable
## Generated by deepin-installer
deb [by-hash=force] http://packages.deepin.com/deepin lion main contrib non-free
#deb-src http://packages.deepin.com/deepin lion main contrib non-free
# docker
deb [arch=amd64] https://mirrors.ustc.edu.cn/docker-ce/linux/debian stretch stable
更新安装
sudo apt-get update
sudo apt-get install docker-ce
让普通用户也能运行 docker
sudo usermod -aG docker $USER
注销或重启电脑
推荐阅读
- JS中的各种宽高度定义及其应用
- 祖母走了
- 唯独你最得我意
- Mac安装Chromedriver
- 人生感悟记#环境仪器宋庆国成长记#072
- 危险也是机会
- MongoDB,Wondows下免安装版|MongoDB,Wondows下免安装版 (简化版操作)
- “精神病患者”的角度问题
- 对抗抑郁最好的方法
- 放下心中的偶像包袱吧