Merge pull request #450 from mwhudson/no-network-no-proxy

do not use apt proxy during no-network install
This commit is contained in:
Dimitri John Ledkov 2019-04-11 00:40:03 +01:00 committed by GitHub
commit 5c90e5efda
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -49,6 +49,7 @@ setup_overlay () {
setup_overlay $TARGET_MOUNT_POINT/etc/apt
mount -t tmpfs tmpfs "$TARGET_MOUNT_POINT/run"
mkdir -p "$TARGET_MOUNT_POINT/run/cdrom"
mount --bind /cdrom "$TARGET_MOUNT_POINT/run/cdrom"
@ -56,6 +57,8 @@ mount --bind /cdrom "$TARGET_MOUNT_POINT/run/cdrom"
if [ $HAS_NETWORK = 'true' ]; then
mv "$TARGET_MOUNT_POINT/etc/apt/sources.list" "$TARGET_MOUNT_POINT/etc/apt/sources.list.d/original.list"
else
# Do not use the configured proxy during the install if one was configured.
rm -f $TARGET_MOUNT_POINT/etc/apt/apt.conf.d/90curtin-aptproxy
setup_overlay $TARGET_MOUNT_POINT/var/lib/apt/lists
fi