apt-get-update在使用debiansource时发布了一个错误



我的dockerfile如下:

FROM wordpress:5.5.1-php7.4
RUN echo 'deb http://ftp.us.debian.org/debian sid main' >> /etc/apt/sources.list
RUN apt-get update && 
apt-get install -y wget sudo && 
apt-get install -y ssmtp

在过去的几个月里没有运行构建,现在我在构建时出现了以下错误

Step 20/45 : RUN echo 'deb http://ftp.us.debian.org/debian sid main' >> /etc/apt/sources.list
---> Running in bded7d792d7e
Removing intermediate container bded7d792d7e
---> 241596b3bdc2
Step 21/45 : RUN apt-get update &&   apt-get install -y wget sudo &&   apt-get install -y ssmtp
---> Running in 4870366692cf
Get:1 http://security.debian.org/debian-security buster/updates InRelease [65.4 kB]
Get:2 http://deb.debian.org/debian buster InRelease [121 kB]
Get:3 http://deb.debian.org/debian buster-updates InRelease [51.9 kB]
Get:4 http://ftp.us.debian.org/debian sid InRelease [146 kB]
Get:5 http://security.debian.org/debian-security buster/updates/main amd64 Packages [243 kB]
Get:6 http://deb.debian.org/debian buster/main amd64 Packages [7906 kB]
Get:7 http://ftp.us.debian.org/debian sid/main amd64 Packages [8492 kB]
Get:8 http://deb.debian.org/debian buster-updates/main amd64 Packages [7856 B]
Fetched 17.0 MB in 3s (6517 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
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:
libc6-dev : Breaks: libgcc-8-dev (< 8.4.0-2~) but 8.3.0-6 is to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
The command '/bin/sh -c apt-get update &&   apt-get install -y wget sudo &&   apt-get install -y 
ssmtp' returned a non-zero code: 100
##[error]The command '/bin/sh -c apt-get update &&   apt-get install -y wget sudo &&   apt-get 
install -y ssmtp' returned a non-zero code: 100
##[error]The process '/usr/bin/docker' failed with exit code 100

我试着完全删除gcc,但没有成功。。尝试了多个其他debian来源,但没有运气,,有人面临类似的问题吗??

我也有同样的错误。删除这条线对我有效:

RUN echo 'deb http://ftp.us.debian.org/debian sid main' >> /etc/apt/sources.list

当然,这取决于你为什么有那条线,在我的情况下,我不需要它,它是这个错误的罪魁祸首。

相关内容

最新更新