index : devtools32 | |
Archlinux32 fork of devtools | gitolite user |
summaryrefslogtreecommitdiff |
author | Felix Yan <felixonmars@archlinux.org> | 2024-03-30 06:18:07 +0200 |
---|---|---|
committer | Christian Heusel <christian@heusel.eu> | 2024-04-28 17:06:46 +0200 |
commit | e828111ff7094354da6d55e1bc19d2d8decf3d6d (patch) | |
tree | ee2793309a2f83aa6870ade09938929d5e2c23af /src | |
parent | 35b417d226fc3d11ac0015abdcb3594d2c696c2e (diff) |
-rw-r--r-- | src/arch-nspawn.in | 3 |
diff --git a/src/arch-nspawn.in b/src/arch-nspawn.in index 2318813..a4504a1 100644 --- a/src/arch-nspawn.in +++ b/src/arch-nspawn.in @@ -72,6 +72,7 @@ fi # shellcheck disable=2016 host_mirrors=($(pacman-conf --repo extra Server 2> /dev/null | sed -r 's#(.*/)extra/os/.*#\1$repo/os/$arch#')) +host_cachemirrors=($(pacman-conf --repo extra CacheServer 2> /dev/null | sed -r 's#(.*/)extra/os/.*#\1$repo/os/$arch#')) for host_mirror in "${host_mirrors[@]}"; do if [[ $host_mirror == *file://* ]]; then @@ -106,6 +107,8 @@ copy_hostconf () { printf 'Server = %s\n' "${host_mirrors[@]}" >"$working_dir/etc/pacman.d/mirrorlist" + [[ -n $host_cachemirrors ]] && printf 'CacheServer = %s\n' "${host_cachemirrors[@]}" >>"$working_dir/etc/pacman.d/mirrorlist" + [[ -n $pac_conf ]] && cp "$pac_conf" "$working_dir/etc/pacman.conf" [[ -n $makepkg_conf ]] && cp "$makepkg_conf" "$working_dir/etc/makepkg.conf" |