apt-get update fails with 404 in a previously working build
This is due to the fact that
as Wheezy and Jessie have been integrated into the archive.debian.org structure recently, we are now removing all of Wheezy and all non-LTS architectures of Jessie from the mirror network starting today.
(As you can read here)
A solution (according to https://github.com/debuerreotype/docker-debian-artifacts/issues/66#issuecomment-476616579) is to add this line:
RUN sed -i '/jessie-updates/d' /etc/apt/sources.list # Now archived
into your Dockerfile before calling any apt-get update
when using debian:jessie. This will remove the jessie-updates
repository (which now causes the 404) from sources.list.
So while the following doesn't work:
FROM debian:jessie
RUN apt-get update
CMD /bin/sh
It works like:
FROM debian:jessie
RUN sed -i '/jessie-updates/d' /etc/apt/sources.list # Now archived
RUN apt-get update
CMD /bin/sh