【发布时间】:2018-12-13 12:00:39
【问题描述】:
感谢您查看此内容。我使用https://github.com/kartoza/docker-ssh为 ssh 创建了一个 docker 映像
唯一不同的是我使用的是 ubuntu:trusty。
在此之后,我启动了容器并通过 ssh 进入容器,然后我尝试安装 python,得到以下信息:
root@a20f46f358b3:/script/docker/ubuntu-trusty# sudo apt-get -qq -y --no-
install-recommends install python-dev
E: Unable to correct problems, you have held broken packages.
root@a20f46f358b3:/peloton/peloton/script/docker/ubuntu-trusty# sudo apt-get
install python-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
python-dev : Depends: libpython-dev (= 2.7.5-5ubuntu3) but it is not going
to be installed
Depends: python2.7-dev (>= 2.7.5-1~) but it is not going to be
installed
E: Unable to correct problems, you have held broken packages.
我应该使用不同的图像来创建容器吗?
没有保存的包,我通过执行验证,没有输出。
dpkg --get-selections | grep hold
有什么想法可以解决这个问题吗?非常感谢您的指导。
问候, ~灰
【问题讨论】:
标签: python docker ubuntu apt-get