Fix no mirrorlist in built image

main
Menci 2021-12-08 02:34:48 +08:00
parent 864d88e36a
commit 67acf5e440
No known key found for this signature in database
GPG Key ID: 175973D9764BC89F
5 changed files with 13 additions and 8 deletions

View File

@ -5,6 +5,8 @@ COPY files /files
RUN \
apk add arch-install-scripts pacman-makepkg curl && \
cat /files/repos-$TARGETARCH >> /etc/pacman.conf && \
mkdir -p /etc/pacman.d && \
cp /files/mirrorlist-$TARGETARCH /etc/pacman.d/mirrorlist && \
if [[ "$TARGETARCH" == "amd64" ]]; then \
apk add zstd && \
mkdir /tmp/archlinux-keyring && \
@ -19,6 +21,7 @@ RUN \
pacman-key --populate && \
mkdir /rootfs && \
/files/pacstrap-docker /rootfs $PACKAGE_GROUP && \
cp /etc/pacman.d/mirrorlist /rootfs/etc/pacman.d/mirrorlist && \
echo "en_US.UTF-8 UTF-8" > /rootfs/etc/locale.gen && \
echo "LANG=en_US.UTF-8" > /rootfs/etc/locale.conf && \
chroot /rootfs locale-gen && \

View File

@ -0,0 +1 @@
Server = http://mirrors.xtom.com/archlinux/$repo/os/$arch

View File

@ -0,0 +1 @@
Server = http://mirror.archlinuxarm.org/$arch/$repo

View File

@ -1,8 +1,8 @@
[core]
Server = http://mirror.rackspace.com/archlinux/$repo/os/$arch
Include = /etc/pacman.d/mirrorlist
[extra]
Server = http://mirror.rackspace.com/archlinux/$repo/os/$arch
Include = /etc/pacman.d/mirrorlist
[community]
Server = http://mirror.rackspace.com/archlinux/$repo/os/$arch
Include = /etc/pacman.d/mirrorlist

View File

@ -1,14 +1,14 @@
[core]
Server = http://mirror.archlinuxarm.org/$arch/$repo
Include = /etc/pacman.d/mirrorlist
[extra]
Server = http://mirror.archlinuxarm.org/$arch/$repo
Include = /etc/pacman.d/mirrorlist
[community]
Server = http://mirror.archlinuxarm.org/$arch/$repo
Include = /etc/pacman.d/mirrorlist
[alarm]
Server = http://mirror.archlinuxarm.org/$arch/$repo
Include = /etc/pacman.d/mirrorlist
[aur]
Server = http://mirror.archlinuxarm.org/$arch/$repo
Include = /etc/pacman.d/mirrorlist