pacstrap: disable DownloadUser in pacman.conf

Fixes: https://gitlab.archlinux.org/archlinux/arch-install-scripts/-/issues/68

Signed-off-by: Morten Linderud <morten@linderud.pw>
This commit is contained in:
Morten Linderud 2024-10-20 20:40:09 +02:00
parent cafd968c2a
commit a60ad80361
No known key found for this signature in database
GPG Key ID: 9C02FF419FECBE16

View File

@ -139,6 +139,11 @@ shift
[[ -d $newroot ]] || die "%s is not a directory" "$newroot"
tmpfile="$(mktemp -t pacman.conf.XXXX)"
cp "$pacman_config" "$tmpfile"
sed -i 's/^DownloadUser/#&/' "$tmpfile"
pacman_config="$tmpfile"
pacman_args+=("$pacmode" "${@:-base}" --config="$pacman_config" --disable-sandbox)
if (( ! hostcache )); then
@ -156,3 +161,7 @@ else
setup=chroot_setup
pacstrap
fi
# TODO: There is a trap check on exit. Need to rework the trap handling with
# hook-ins/callbacks to remove aux files
rm "$tmpfile"