diff options
author | Lyndon Brown <jnqnfe@gmail.com> | 2020-03-19 01:37:59 +0000 |
---|---|---|
committer | Luca Boccassi <bluca@debian.org> | 2020-03-20 10:19:33 +0000 |
commit | 2c14566c69b2ab60d21424ab76bbda53acce6bcf (patch) | |
tree | 24ae7884c8dc69eaf91436186cdb600ee6cc4ea7 /functions | |
parent | 945a166f75f7bf0419a7caefa7e7337119732929 (diff) | |
download | vyos-live-build-2c14566c69b2ab60d21424ab76bbda53acce6bcf.tar.gz vyos-live-build-2c14566c69b2ab60d21424ab76bbda53acce6bcf.zip |
defaults: tidy mirrors
Diffstat (limited to 'functions')
-rwxr-xr-x | functions/defaults.sh | 49 |
1 files changed, 18 insertions, 31 deletions
diff --git a/functions/defaults.sh b/functions/defaults.sh index 52607a173..fd9129ed5 100755 --- a/functions/defaults.sh +++ b/functions/defaults.sh @@ -222,41 +222,28 @@ Set_config_defaults () ## config/bootstrap - # Setting mirror to fetch packages from - case "${LB_MODE}" in - debian) - LB_MIRROR_BOOTSTRAP="${LB_MIRROR_BOOTSTRAP:-http://deb.debian.org/debian/}" - LB_PARENT_MIRROR_BOOTSTRAP="${LB_PARENT_MIRROR_BOOTSTRAP:-${LB_MIRROR_BOOTSTRAP}}" - ;; - esac - - LB_PARENT_MIRROR_CHROOT="${LB_PARENT_MIRROR_CHROOT:-${LB_PARENT_MIRROR_BOOTSTRAP}}" + # Setting mirrors + # *_MIRROR_CHROOT: to fetch packages from + # *_MIRROR_BOOTSTRAP: to fetch packages from + # *_MIRROR_CHROOT_SECURITY: security mirror to fetch packages from + # *_MIRROR_BINARY: mirror which ends up in the image + # *_MIRROR_BINARY_SECURITY: security mirror which ends up in the image + # *_MIRROR_DEBIAN_INSTALLER: to fetch installer from LB_MIRROR_CHROOT="${LB_MIRROR_CHROOT:-${LB_MIRROR_BOOTSTRAP}}" + LB_PARENT_MIRROR_CHROOT="${LB_PARENT_MIRROR_CHROOT:-${LB_PARENT_MIRROR_BOOTSTRAP}}" + if [ "${LB_MODE}" = "debian" ]; then + LB_MIRROR_BOOTSTRAP="${LB_MIRROR_BOOTSTRAP:-http://deb.debian.org/debian/}" + LB_PARENT_MIRROR_BOOTSTRAP="${LB_PARENT_MIRROR_BOOTSTRAP:-${LB_MIRROR_BOOTSTRAP}}" - # Setting security mirror to fetch packages from - case "${LB_MODE}" in - debian) - LB_MIRROR_CHROOT_SECURITY="${LB_MIRROR_CHROOT_SECURITY:-http://security.debian.org/}" - LB_PARENT_MIRROR_CHROOT_SECURITY="${LB_PARENT_MIRROR_CHROOT_SECURITY:-${LB_MIRROR_CHROOT_SECURITY}}" - ;; - esac - - # Setting mirror which ends up in the image - case "${LB_MODE}" in - debian) - LB_MIRROR_BINARY="${LB_MIRROR_BINARY:-http://deb.debian.org/debian/}" - LB_PARENT_MIRROR_BINARY="${LB_PARENT_MIRROR_BINARY:-${LB_MIRROR_BINARY}}" - ;; - esac + LB_MIRROR_CHROOT_SECURITY="${LB_MIRROR_CHROOT_SECURITY:-http://security.debian.org/}" + LB_PARENT_MIRROR_CHROOT_SECURITY="${LB_PARENT_MIRROR_CHROOT_SECURITY:-${LB_MIRROR_CHROOT_SECURITY}}" - # Setting security mirror which ends up in the image - case "${LB_MODE}" in - debian) - LB_MIRROR_BINARY_SECURITY="${LB_MIRROR_BINARY_SECURITY:-http://security.debian.org/}" - LB_PARENT_MIRROR_BINARY_SECURITY="${LB_PARENT_MIRROR_BINARY_SECURITY:-${LB_MIRROR_BINARY_SECURITY}}" - ;; - esac + LB_MIRROR_BINARY="${LB_MIRROR_BINARY:-http://deb.debian.org/debian/}" + LB_PARENT_MIRROR_BINARY="${LB_PARENT_MIRROR_BINARY:-${LB_MIRROR_BINARY}}" + LB_MIRROR_BINARY_SECURITY="${LB_MIRROR_BINARY_SECURITY:-http://security.debian.org/}" + LB_PARENT_MIRROR_BINARY_SECURITY="${LB_PARENT_MIRROR_BINARY_SECURITY:-${LB_MIRROR_BINARY_SECURITY}}" + fi LB_MIRROR_DEBIAN_INSTALLER="${LB_MIRROR_DEBIAN_INSTALLER:-${LB_MIRROR_CHROOT}}" LB_PARENT_MIRROR_DEBIAN_INSTALLER="${LB_PARENT_MIRROR_DEBIAN_INSTALLER:-${LB_PARENT_MIRROR_CHROOT}}" |