Skip to content

Commit

Permalink
Resolve build container errors (#1208)
Browse files Browse the repository at this point in the history
Fixes

```
#21 22.27 Get:2 http://ftp.ports.debian.org/debian-ports unreleased InRelease [50.3 kB]
#21 22.34 Err:1 http://ftp.ports.debian.org/debian-ports unstable InRelease
#21 22.34   The following signatures couldn't be verified because the public key is not available: NO_PUBKEY B523E5F3FC4E5F2C NO_PUBKEY 8D69674688B6CB36
#21 22.42 Err:2 http://ftp.ports.debian.org/debian-ports unreleased InRelease
#21 22.42   The following signatures couldn't be verified because the public key is not available: NO_PUBKEY B523E5F3FC4E5F2C NO_PUBKEY 8D69674688B6CB36
#21 22.43 Reading package lists...
#21 22.44 W: GPG error: http://ftp.ports.debian.org/debian-ports unstable InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY B523E5F3FC4E5F2C NO_PUBKEY 8D69674688B6CB36
#21 22.44 E: The repository 'http://ftp.ports.debian.org/debian-ports unstable InRelease' is not signed.
#21 22.44 W: GPG error: http://ftp.ports.debian.org/debian-ports unreleased InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY B523E5F3FC4E5F2C NO_PUBKEY 8D69674688B6CB36
#21 22.44 E: The repository 'http://ftp.ports.debian.org/debian-ports unreleased InRelease' is not signed.
```
  • Loading branch information
Emilgardis committed Dec 22, 2023
2 parents 5896ed1 + ace233c commit 3e4f13a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion docker/linux-image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ main() {
# archive.debian.org Release files are expired.
echo "Acquire::Check-Valid-Until false;" | tee -a /etc/apt/apt.conf.d/10-nocheckvalid
echo "APT::Get::AllowUnauthenticated true;" | tee -a /etc/apt/apt.conf.d/10-nocheckvalid
echo "Acquire::AllowInsecureRepositories True;" | tee -a /etc/apt/apt.conf.d/10-nocheckvalid

dropbear="dropbear"
deps=(libcrypt1:"${arch}")
Expand Down Expand Up @@ -201,7 +202,7 @@ main() {
curl --retry 3 -sSfL 'https://ftp-master.debian.org/keys/archive-key-{7.0,8,9,10,11}.asc' -O
curl --retry 3 -sSfL 'https://ftp-master.debian.org/keys/archive-key-{8,9,10,11}-security.asc' -O
curl --retry 3 -sSfL 'https://ftp-master.debian.org/keys/release-{7,8,9,10,11}.asc' -O
curl --retry 3 -sSfL 'https://www.ports.debian.org/archive_{2020,2021,2022}.key' -O
curl --retry 3 -sSfL 'https://www.ports.debian.org/archive_{2020,2021,2022,2023}.key' -O

for key in *.asc *.key; do
apt-key add "${key}"
Expand Down Expand Up @@ -398,6 +399,9 @@ EOF
if [ -f /etc/dpkg/dpkg.cfg.d/multiarch.bak ]; then
mv /etc/dpkg/dpkg.cfg.d/multiarch.bak /etc/dpkg/dpkg.cfg.d/multiarch
fi
if [ -f /etc/apt/apt.conf.d/10-nocheckvalid ]; then
rm /etc/apt/apt.conf.d/10-nocheckvalid
fi
# can fail if arch is used (image arch, such as amd64 and/or i386)
dpkg --remove-architecture "${arch}" || true
apt-get update
Expand Down

0 comments on commit 3e4f13a

Please sign in to comment.