安装docker

时间:2017-07-28 16:21:43

标签: linux ubuntu docker

根据说明安装码头工具:

https://docs.docker.com/engine/installation/linux/docker-ee/ubuntu/#install-using-the-repository

我有错误:

E: Unable to locate package docker-ee

更新包的索引时返回错误:

W: Failed to fetch https://download.docker.com/linux/ubuntu/dists/trusty/InRelease  Unable to find expected entry 'stable-17.03/binary-amd64/Packages' in Release file (Wrong sources.list entry or malformed file)

这是什么错误?

p.s

lsb_release
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.5 LTS
Release:    14.04
Codename:   trusty

uname -a
Linux dev-Cherepanov 4.2.0-27-generic #32~14.04.1-Ubuntu SMP Fri Jan 22 15:32:26 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

2 个答案:

答案 0 :(得分:0)

ubuntu 14.04 linux-image-extra- *软件包有一些额外的软件包,它们允许Docker EE使用aufs存储驱动程序,这里有命令:

 $ sudo apt-get update

$ sudo apt-get install \
    linux-image-extra-$(uname -r) \
    linux-image-extra-virtual

然后设置存储库:

$ sudo apt-get update
$ sudo apt-get install \
    apt-transport-https \
    ca-certificates \
    curl \
    software-properties-common
 $ curl -fsSL <DOCKER-EE-URL>/ubuntu/gpg | sudo apt-key add -
$ apt-key fingerprint 6D085F96

pub   4096R/6D085F96 2017-02-22
    Key fingerprint = DD91 1E99 5A64 A202 E859  07D6 BC14 F10B 6D08 5F96
uid       [ultimate] Docker Release (EE deb) <docker@docker.com>
sub   4096R/91A29FA3 2017-02-22
$ sudo add-apt-repository \
   "deb [arch=amd64] <DOCKER-EE-URL>/ubuntu \
   $(lsb_release -cs) \
   stable-17.03"

docker-ee的最后一个安装步骤: -

$ sudo apt-get update
$ sudo apt-get install docker-ee

希望这适合您。

答案 1 :(得分:0)

你可以尝试运行

$ sudo add-apt-repository \
    "deb [arch=amd64] <DOCKER-EE-URL>/ubuntu \
    $(lsb_release -cs) \
    stable"

$sudo add-apt-repository \
   "deb [arch=amd64] <DOCKER-EE-URL>/ubuntu \
   $(lsb_release -cs) \
   stable-17.03"

然后

$ sudo apt-get update
$ sudo apt-get install docker-ee