Add reuse proxy

pull/34/head
Bohan Yang 4 years ago
parent cbf1d3d64e
commit 9148d3c1fd
  1. 1
      README.md
  2. 5
      debi.sh

@ -110,6 +110,7 @@ Otherwise, you can run this command to revert all changes made by the script:
* `--daily-d-i` Use latest daily build of d-i (Debian Installer) for the unreleased version: 12 (bookworm), sid (unstable) * `--daily-d-i` Use latest daily build of d-i (Debian Installer) for the unreleased version: 12 (bookworm), sid (unstable)
* `--mirror-protocol http` or `https` or `ftp` * `--mirror-protocol http` or `https` or `ftp`
* `--https` alias to `--mirror-protocol https` * `--https` alias to `--mirror-protocol https`
* `--reuse-proxy` Reuse the value of `http(s)_proxy` environment variable as the mirror proxy
* `--proxy, --mirror-proxy` Set an HTTP proxy for APT and downloads * `--proxy, --mirror-proxy` Set an HTTP proxy for APT and downloads
* `--mirror-host deb.debian.org` * `--mirror-host deb.debian.org`
* `--mirror-directory /debian` * `--mirror-directory /debian`

@ -306,6 +306,9 @@ while [ $# -gt 0 ]; do
mirror_proxy=$2 mirror_proxy=$2
shift shift
;; ;;
--reuse-proxy)
set_mirror_proxy
;;
--security-repository) --security-repository)
security_repository=$2 security_repository=$2
shift shift
@ -531,8 +534,6 @@ EOF
echo 'd-i network-console/start select Continue' | $save_preseed echo 'd-i network-console/start select Continue' | $save_preseed
} }
set_mirror_proxy
$save_preseed << EOF $save_preseed << EOF
# Mirror settings # Mirror settings

Loading…
Cancel
Save