docker - 无法找到包(两台服务器除版本外设置相同)

docker - 无法找到包(两台服务器除版本外设置相同)

较新的 Docker 是否有不同的源列表或类似的?

a# docker --version
Docker version 1.10.1, build 9e83765

b# docker --version
Docker version 1.9.1, build a34a1d5

安装通过旧版本进行,但不通过新版本。

"
E: Unable to locate package supervisor
E: Unable to locate package python-pystache
"

这是两者的基本 Dockerfile:

# cat Dockerfile
FROM ubuntu:14.04
ENV http_proxy 'http://proxy.us.wsa.com:80'
ENV https_proxy 'http://proxy.us.wsa.com:80'
ENV HTTP_PROXY 'http://proxy.us.wsa.com:80'
ENV HTTPS_PROXY 'http://proxy.us.wsa.com:80'
ENV DEBIAN_FRONTEND noninteractive 
RUN rm /bin/sh && ln -s /bin/bash /bin/sh

COPY apt.conf /etc/apt/apt.conf
RUN apt-get -y update
RUN apt-get install -y vim supervisor python2.7 openjdk-7-jdk python-pystache make

COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
CMD ["/usr/bin/supervisord"]

服务器 a 和 b 都有相同的代理设置,/etc/environment等等/etc/default/docker

按照其他人的建议尝试如下:

"
RUN add-apt-repository main
RUN add-apt-repository universe
RUN add-apt-repository restricted
RUN add-apt-repository multivers
"

但 ” sudo: add-apt-repository: command not found

这里毫无线索。

再次感谢。

答案1

“Michael Hampton” 说得对。寻求稳定时,一定要远离前沿技术。

a# docker --version
Docker version 1.9.1, build a34a1d5

一切都好。

Selecting previously unselected package libgraphite2-3:amd64.
Preparing to unpack .../libgraphite2-3_1.2.4-1ubuntu1.1_amd64.deb ...
Unpacking libgraphite2-3:amd64 (1.2.4-1ubuntu1.1) ...
Selecting previously unselected package libharfbuzz0b:amd64.
Preparing to unpack .../libharfbuzz0b_0.9.27-1ubuntu1_amd64.deb ...
Unpacking libharfbuzz0b:amd64 (0.9.27-1ubuntu1) ...
Selecting previously unselected package libpangoft2-1.0-0:amd64.
Preparing to unpack .../libpangoft2-1.0-0_1.36.3-1ubuntu1.1_amd64.deb ...
Unpacking libpangoft2-1.0-0:amd64 (1.36.3-1ubuntu1.1) ...
Selecting previously unselected package libpangocairo-1.0-0:amd64.
Preparing to unpack .../libpangocairo-1.0-0_1.36.3-1ubuntu1.1_amd64.deb ...
Unpacking libpangocairo-1.0-0:amd64 (1.36.3-1ubuntu1.1) ...

如果有人想知道,这些是安装特定版本的 Docker 的简单步骤。有时,当它抱怨现有的依赖项时,请在降级/升级之前手动删除该单个依赖项。

  274  sudo apt-get remove -y docker-engine
  286  wget https://get.docker.io/ | DOCKER_VERSION=1.9.1 sh --proxy=on
  287  history | grep docker
  288  ls
  289  apt-get install -y docker-engine=1.9.1
  290  exit

相关内容