aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsickcodes <[email protected]>2022-11-16 14:25:24 +0000
committersickcodes <[email protected]>2022-11-16 14:25:24 +0000
commit9aac2dbe7f3d633620a64c9c805bce1722a446e8 (patch)
treea8dfa96c39ea990300e7c75ccc657468492230c5
parentUpdate submodules (diff)
downloaddocker-osx-9aac2dbe7f3d633620a64c9c805bce1722a446e8.tar.xz
docker-osx-9aac2dbe7f3d633620a64c9c805bce1722a446e8.zip
Fix keyring `pacman-key --populate archlinux`
-rw-r--r--Dockerfile10
1 files changed, 6 insertions, 4 deletions
diff --git a/Dockerfile b/Dockerfile
index 5327998..9f1032d 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -67,9 +67,14 @@ ARG RANKMIRRORS
ARG MIRROR_COUNTRY=US
ARG MIRROR_COUNT=10
+# Fixes issue with invalid GPG keys: update the archlinux-keyring package to get the latest keys, then remove and regenerate gnupg keys
+RUN rm -rf /etc/pacman.d/gnupg \
+ && pacman-key --init \
+ && pacman-key --populate archlinux
+
RUN if [[ "${RANKMIRRORS}" ]]; then \
{ pacman -Sy wget --noconfirm || pacman -Syu wget --noconfirm ; } \
- ; wget -O ./rankmirrors "https://raw.githubusercontent.com/sickcodes/Docker-OSX/master/rankmirrors" \
+ ; wget -O ./rankmirrors "https://raw.githubusercontent.com/sickcodes/Docker-OSX/${BRANCH:=master}/rankmirrors" \
; wget -O- "https://www.archlinux.org/mirrorlist/?country=${MIRROR_COUNTRY:-US}&protocol=https&use_mirror_status=on" \
| sed -e 's/^#Server/Server/' -e '/^#/d' \
| head -n "$((${MIRROR_COUNT:-10}+1))" \
@@ -80,9 +85,6 @@ RUN if [[ "${RANKMIRRORS}" ]]; then \
&& cat /etc/pacman.d/mirrorlist \
; fi
-# Fixes issue with invalid GPG keys: update the archlinux-keyring package to get the latest keys, then remove and regenerate gnupg keys
-RUN pacman -Sy archlinux-keyring --noconfirm && rm -rf /etc/pacman.d/gnupg && pacman-key --init && pacman-key --populate
-
RUN tee -a /etc/pacman.d/gnupg/gpg.conf <<< 'keyserver hkp://keyserver.ubuntu.com' \
&& tee -a /etc/pacman.d/gnupg/gpg.conf <<< 'keyserver hkps://hkps.pool.sks-keyservers.net:443' \
&& tee -a /etc/pacman.d/gnupg/gpg.conf <<< 'keyserver hkp://pgp.mit.edu:11371' \