基本上我有:
FROM ubuntu:18.04
RUN apt update
RUN apt install -y software-properties-common ca-certificates wget curl ssh
RUN apt install -y build-essential
最终结果如下:
...
Get:48 http://archive.ubuntu.com/ubuntu bionic/main amd64 libalgorithm-merge-perl all 0.08-3 [12.0 kB]
Get:49 http://archive.ubuntu.com/ubuntu bionic/main amd64 libfile-fcntllock-perl amd64 0.22-3build2 [33.2 kB]
Get:50 http://archive.ubuntu.com/ubuntu bionic/main amd64 manpages-dev all 4.15-1 [2217 kB]
Fetched 44.2 MB in 3s (15.0 MB/s)
E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/main/l/linux/linux-libc-dev_4.15.0-19.20_amd64.deb 404 Not Found [IP: 91.189.88.149 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
The command '/bin/sh -c apt install -y build-essential' returned a non-zero code: 100
现在有一些破损的包裹吗?
答案1
通过交给--no-cache
Docker 解决了这个问题。