Skip to contentSkip to conversation

docker: Use a stable snapshot for Debian Sid

PATCH Applied Philippe Mathieu-Daudé 5 participants 7 messages Nov 1, 2018 – Jan 10, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 docker: Use a stable snapshot for Debian Sid

The Debian Sid repository is not garanteed to be stable, as his 'unstable' name suggest :)
To allow quick testing, packages are pushed various time a day, which my be annoying when trying to use it for stable development (which is not recommended, but Sid provides edge packages we use for testing).

Debian provides repositories snapshots which are suitable for our use. Pick a recent date that works. When required, update to newer releases will be easy.

This fixes current issues with this image:

  $ make docker-image-debian-sid
  [...]
  The following packages have unmet dependencies:
   build-essential : Depends: dpkg-dev (>= 1.17.11) but it is not going to be installed
   git : Depends: perl but it is not going to be installed
         Depends: liberror-perl but it is not going to be installed
   pkg-config : Depends: libdpkg-perl but it is not going to be installed
   texinfo : Depends: perl (>= 5.26.2-6) but it is not going to be installed
             Depends: libtext-unidecode-perl but it is not going to be installed
             Depends: libxml-libxml-perl but it is not going to be installed
  E: Unable to correct problems, you have held broken packages.
---
 tests/docker/dockerfiles/debian-sid.docker | 4 ++++
 1 file changed, 4 insertions(+)
tests/docker/dockerfiles/debian-sid.docker +4 -0
index 9a3d168705..4e4cda0ba5 100644
@@ -13,6 +13,10 @@
 
 FROM debian:sid-slim
 
+# Use a snapshot known to work (see http://snapshot.debian.org/#Usage)
+ENV DEBIAN_SNAPSHOT_DATE "20181030"
+RUN sed -i "s%^deb \(https\?://\)deb.debian.org/debian/\? \(.*\)%deb [check-valid-until=no] \1snapshot.debian.org/archive/debian/${DEBIAN_SNAPSHOT_DATE} \2%" /etc/apt/sources.list
+
 # Duplicate deb line as deb-src
 RUN cat /etc/apt/sources.list | sed "s/^deb\ /deb-src /" >> /etc/apt/sources.list
 
Signature · 1 line
2.17.2
Applied
#1 lore raw
Quoted 48 lines · Philippe Mathieu-Daudé

The Debian Sid repository is not garanteed to be stable, as his 'unstable' name suggest :)
To allow quick testing, packages are pushed various time a day, which my be annoying when trying to use it for stable development (which is not recommended, but Sid provides edge packages we use for testing).

Debian provides repositories snapshots which are suitable for our use. Pick a recent date that works. When required, update to newer releases will be easy.

This fixes current issues with this image:

  $ make docker-image-debian-sid
  [...]
  The following packages have unmet dependencies:
   build-essential : Depends: dpkg-dev (>= 1.17.11) but it is not going to be installed
   git : Depends: perl but it is not going to be installed
         Depends: liberror-perl but it is not going to be installed
   pkg-config : Depends: libdpkg-perl but it is not going to be installed
   texinfo : Depends: perl (>= 5.26.2-6) but it is not going to be installed
             Depends: libtext-unidecode-perl but it is not going to be installed
             Depends: libxml-libxml-perl but it is not going to be installed
  E: Unable to correct problems, you have held broken packages.
---
 tests/docker/dockerfiles/debian-sid.docker | 4 ++++
 1 file changed, 4 insertions(+)
tests/docker/dockerfiles/debian-sid.docker +4 -0
index 9a3d168705..4e4cda0ba5 100644
@@ -13,6 +13,10 @@
 
 FROM debian:sid-slim
 
+# Use a snapshot known to work (see http://snapshot.debian.org/#Usage)
+ENV DEBIAN_SNAPSHOT_DATE "20181030"
+RUN sed -i "s%^deb \(https\?://\)deb.debian.org/debian/\? \(.*\)%deb [check-valid-until=no] \1snapshot.debian.org/archive/debian/${DEBIAN_SNAPSHOT_DATE} \2%" /etc/apt/sources.list
+
 # Duplicate deb line as deb-src
 RUN cat /etc/apt/sources.list | sed "s/^deb\ /deb-src /" >> /etc/apt/sources.list
 
Signature · 1 line
2.17.2

Queued, thanks!

Fam

#2 lore raw

Hi Fam,

Thanks for picking this.

Quoted 3 lines · Fam Zheng
Quoted 2 lines · Philippe Mathieu-Daudé

The Debian Sid repository is not garanteed to be stable, as his 'unstable' name suggest :)

There is an error in "my be" -> "might be"...
Do you mind to update the comment:

Quoted 4 lines
Quoted 4 lines

To allow quick testing, packages are pushed various time a day, which my be annoying when trying to use it for stable development (which is not recommended, but Sid provides edge packages we use for testing).

By:

To allow quick testing, Debian maintainers might push packages various time a day. Sometime package dependencies might break, which is annoying when using this repository for stable development (which is not recommended, but Sid provides edge packages we use for testing).

I can resend as v2 if you prefer.

Thanks!

Phil.

Quoted 48 lines
Quoted 42 lines

(which is not recommended, but Sid provides edge packages we use for testing).

Debian provides repositories snapshots which are suitable for our use. Pick a recent date that works. When required, update to newer releases will be easy.

This fixes current issues with this image:

  $ make docker-image-debian-sid
  [...]
  The following packages have unmet dependencies:
   build-essential : Depends: dpkg-dev (>= 1.17.11) but it is not going to be installed
   git : Depends: perl but it is not going to be installed
         Depends: liberror-perl but it is not going to be installed
   pkg-config : Depends: libdpkg-perl but it is not going to be installed
   texinfo : Depends: perl (>= 5.26.2-6) but it is not going to be installed
             Depends: libtext-unidecode-perl but it is not going to be installed
             Depends: libxml-libxml-perl but it is not going to be installed
  E: Unable to correct problems, you have held broken packages.
---
 tests/docker/dockerfiles/debian-sid.docker | 4 ++++
 1 file changed, 4 insertions(+)
tests/docker/dockerfiles/debian-sid.docker +4 -1
index 9a3d168705..4e4cda0ba5 100644
@@ -13,6 +13,10 @@
 
 FROM debian:sid-slim
 
+# Use a snapshot known to work (see http://snapshot.debian.org/#Usage)
+ENV DEBIAN_SNAPSHOT_DATE "20181030"
+RUN sed -i "s%^deb \(https\?://\)deb.debian.org/debian/\? \(.*\)%deb [check-valid-until=no] \1snapshot.debian.org/archive/debian/${DEBIAN_SNAPSHOT_DATE} \2%" /etc/apt/sources.list
+
 # Duplicate deb line as deb-src
 RUN cat /etc/apt/sources.list | sed "s/^deb\ /deb-src /" >> /etc/apt/sources.list
 
--
Quoted 2 lines

2.17.2

Queued, thanks!

Fam

#3 lore raw
Quoted 18 lines · Philippe Mathieu-Daudé

Hi Fam,

Thanks for picking this.

Quoted 3 lines · Fam Zheng
Quoted 2 lines · Philippe Mathieu-Daudé

The Debian Sid repository is not garanteed to be stable, as his 'unstable' name suggest :)

There is an error in "my be" -> "might be"...
Do you mind to update the comment:

Quoted 4 lines
Quoted 4 lines

To allow quick testing, packages are pushed various time a day, which my be annoying when trying to use it for stable development (which is not recommended, but Sid provides edge packages we use for testing).

Quoted 7 lines

By:

To allow quick testing, Debian maintainers might push packages various time a day. Sometime package dependencies might break, which is annoying when using this repository for stable development (which is not recommended, but Sid provides edge packages we use for testing).

Sure, updated in my queue.

Fam

#4 lore raw

Hi Fam,

Quoted 21 lines · Fam Zheng
Quoted 20 lines · Philippe Mathieu-Daudé

Hi Fam,

Thanks for picking this.

Quoted 3 lines · Fam Zheng
Quoted 2 lines · Philippe Mathieu-Daudé

The Debian Sid repository is not garanteed to be stable, as his 'unstable' name suggest :)

There is an error in "my be" -> "might be"...
Do you mind to update the comment:

Quoted 4 lines
Quoted 4 lines

To allow quick testing, packages are pushed various time a day, which my be annoying when trying to use it for stable development (which is not recommended, but Sid provides edge packages we use for testing).

By:

Quoted 7 lines
Quoted 5 lines

To allow quick testing, Debian maintainers might push packages various time a day. Sometime package dependencies might break, which is annoying when using this repository for stable development (which is not recommended, but Sid provides edge packages we use for testing).

Sure, updated in my queue.

It seems your queue never hit master...

#5 lore raw
Quoted 34 lines · Philippe Mathieu-Daudé

Hi Fam,

Quoted 27 lines · Fam Zheng
Quoted 25 lines · Philippe Mathieu-Daudé

Hi Fam,

Thanks for picking this.

Quoted 3 lines · Fam Zheng
Quoted 2 lines · Philippe Mathieu-Daudé

The Debian Sid repository is not garanteed to be stable, as his 'unstable' name suggest :)

There is an error in "my be" -> "might be"...
Do you mind to update the comment:

Quoted 4 lines
Quoted 4 lines

To allow quick testing, packages are pushed various time a day, which my be annoying when trying to use it for stable development (which is not recommended, but Sid provides edge packages we use for testing).

By:

To allow quick testing, Debian maintainers might push packages various time a day. Sometime package dependencies might break, which is annoying when using this repository for stable development (which is not recommended, but Sid provides edge packages we use for testing).

Quoted 4 lines
Quoted 1 line

Sure, updated in my queue.

It seems your queue never hit master…

Oh.. I'll have to check out later today.

Fam

#6 lore raw
In reply to Philippe Mathieu-Daudé
Quoted 35 lines · Philippe Mathieu-Daudé

The Debian Sid repository is not garanteed to be stable, as his 'unstable' name suggest :)
To allow quick testing, packages are pushed various time a day, which my be annoying when trying to use it for stable development (which is not recommended, but Sid provides edge packages we use for testing).

Debian provides repositories snapshots which are suitable for our use. Pick a recent date that works. When required, update to newer releases will be easy.

This fixes current issues with this image:

  $ make docker-image-debian-sid
  [...]
  The following packages have unmet dependencies:
   build-essential : Depends: dpkg-dev (>= 1.17.11) but it is not going to be installed
   git : Depends: perl but it is not going to be installed
         Depends: liberror-perl but it is not going to be installed
   pkg-config : Depends: libdpkg-perl but it is not going to be installed
   texinfo : Depends: perl (>= 5.26.2-6) but it is not going to be installed
             Depends: libtext-unidecode-perl but it is not going to be installed
             Depends: libxml-libxml-perl but it is not going to be installed
  E: Unable to correct problems, you have held broken packages.
---
 tests/docker/dockerfiles/debian-sid.docker | 4 ++++
 1 file changed, 4 insertions(+)
tests/docker/dockerfiles/debian-sid.docker +0 -0
index 9a3d168705..4e4cda0ba5 100644

tests/docker/dockerfiles/debian-sid.docker line 19

Quoted 7 lines
tests/docker/dockerfiles/debian-sid.docker +4 -0
@@ -13,6 +13,10 @@
 
 FROM debian:sid-slim
 
+# Use a snapshot known to work (see http://snapshot.debian.org/#Usage)
+ENV DEBIAN_SNAPSHOT_DATE "20181030"
+RUN sed -i "s%^deb \(https\?://\)deb.debian.org/debian/\? \(.*\)%deb [check-valid-until=no] \1snapshot.debian.org/archive/debian/${DEBIAN_SNAPSHOT_DATE} \2%" /etc/apt/sources.list
+

OK after much debugging and re-building I realise this isn't the whole fix. We need to base the snapshot on an older docker image otherwise we run into the problem of trying to downgrade. In my tree I've done:

# This must be earlier than the snapshot date we are aiming for FROM debian:sid-20181011-slim

# Use a snapshot known to work (see http://snapshot.debian.org/#Usage)
ENV DEBIAN_SNAPSHOT_DATE "20181030"

If this patch hasn't already gone in via a Fam PR I'll include it in my testing/next.

--
Alex Bennée