Skip to content

Commit 0d5bb99

Browse files
authored
Merge pull request #1834 from AntelopeIO/bustersnapshot_12
[1.2.3] use debian's package snapshot repo for old buster packages needed in reproducible build
2 parents 04bdb08 + 41b6fcb commit 0d5bb99

1 file changed

Lines changed: 9 additions & 11 deletions

File tree

tools/reproducible.Dockerfile

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,19 @@
11
# syntax=docker/dockerfile:1
2-
# debian:buster on Sep 20 2023
3-
FROM debian@sha256:d774a984460a74973e6ce4d1f87ab90f2818e41fcdd4802bcbdc4e0b67f9dadf AS builder
2+
# debian:buster on Aug 20 2025 (tag from Jun 12, 2024)
3+
FROM debian@sha256:58ce6f1271ae1c8a2006ff7d3e54e9874d839f573d8009c20154ad0f2fb0a225 AS builder
44

55
# If enabling the snapshot repo below, this ought to be after the base image time from above.
6-
# date -u -d @1695620708 = Mon Sep 25 05:45:08 AM UTC 2023
7-
ENV SOURCE_DATE_EPOCH=1695620708
6+
# date -u -d @1752331000 = Sat Jul 12 02:36:40 PM UTC 2025
7+
ENV SOURCE_DATE_EPOCH=1752331000
88

9-
# The snapshot repo is currently disabled due to poor performance. Re-eval in the future.
109
# When the package repo is signed, a message in the payload indicates the time when the repo becomes stale. This protection
1110
# nominally exists to ensure older versions of the package repo which may contain defective packages aren't served in the far
1211
# future. But in our case, we want this pinned package repo at any future date. So [check-valid-until=no] to disable this check.
13-
##RUN <<EOF
14-
##cat <<EOS > /etc/apt/sources.list
15-
##deb [check-valid-until=no] http://snapshot.debian.org/archive/debian/$(date -d @${SOURCE_DATE_EPOCH} +%Y%m%dT%H%M%SZ)/ buster main
16-
##deb [check-valid-until=no] http://snapshot.debian.org/archive/debian-security/$(date -d @${SOURCE_DATE_EPOCH} +%Y%m%dT%H%M%SZ)/ buster/updates main
17-
##EOS
18-
##EOF
12+
RUN DATETIMESTR=$(date -d @${SOURCE_DATE_EPOCH} +%Y%m%dT%H%M%SZ) && cat <<EOF > /etc/apt/sources.list
13+
deb [check-valid-until=no] http://snapshot.debian.org/archive/debian/${DATETIMESTR}/ buster main
14+
deb [check-valid-until=no] http://snapshot.debian.org/archive/debian/${DATETIMESTR}/ buster-updates main
15+
deb [check-valid-until=no] http://snapshot.debian.org/archive/debian-security/${DATETIMESTR}/ buster/updates main
16+
EOF
1917

2018
RUN apt-get update && apt-get -y upgrade && DEBIAN_FRONTEND=noninteractive apt-get -y install build-essential \
2119
file \

0 commit comments

Comments
 (0)