From 37021a6b1de2087f9a7fab86a4eb638c61909e19 Mon Sep 17 00:00:00 2001 From: Bohan Yang Date: Sat, 22 Sep 2018 18:09:49 +0800 Subject: [PATCH] Update default options --- README.md | 28 ++++++++++++++-------------- netboot.sh | 24 ++++++++++++------------ 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index efc8c68..23bb14f 100644 --- a/README.md +++ b/README.md @@ -29,33 +29,33 @@ sudo sh -c "$(wget -O - https://github.com/brentybh/debian-netboot/raw/master/ne ### All Options - `-c US` Debian Installer Country - - `-fqdn localhost.localdomain` FQDN including hostname and domain - - `-proto https` Transport protocol for archive mirror only but not security repository (`http`, `https`, `ftp`) - - `-host dpvctowv9b08b.cloudfront.net` Host for archive mirror only but not security repository + - `-fqdn unassigned-hostname.unassigned-domain` FQDN including hostname and domain + - `-proto http` Transport protocol for archive mirror only but not security repository (`http`, `https`, `ftp`) + - `-host deb.debian.org` Host for archive mirror only but not security repository - `-dir /debian` Directory path relative to root of the mirror - `-suite stretch` Suite (`stable`, `testing`, `stretch`, etc.) - - `-u ubuntu` Username of admin account with sudo privilege + - `-u debian` Username of admin account with sudo privilege - `-p secret` Password of the account **(if not specified, it will be asked interactively)** - `-tz UTC` [Time zone](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) - - `-ntp time.google.com` NTP server + - `-ntp pool.ntp.org` NTP server - `-upgrade full-upgrade` Whether to upgrade packages after debootstrap (`none`, `safe-upgrade`, `full-upgrade`) - - `-s https://dpvctowv9b08b.cloudfront.net/debian-security` Custom URL for security repository mirror - - `-ip 1.2.3.4` Configure network manually with an IP address (following options only work when IP address specified) + - `-s http://security.debian.org/debian-security` Custom URL for security repository mirror + - `-ip 192.168.1.42` Configure network manually with an IP address (following options only work when IP address specified) - `-cidr 255.255.255.0` Netmask for manual network configuration - - `-gw 1.2.3.1` Gateway for manual network configuration - - `-ns "1.1.1.1 156.154.70.5 8.8.8.8"` DNS for manual network configuration - - `-add "ca-certificates curl openssl"` Include individual additional packages to install + - `-gw 192.168.1.1` Gateway for manual network configuration + - `-ns "8.8.8.8 8.8.4.4"` DNS for manual network configuration + - `-add "ca-certificates curl fail2ban openssl whois"` Include individual additional packages to install - `-ssh secret` Enable network console and specify **password for SSH access during install process**. You can login with `installer` user and check system logs. ### Chinese Special If `-c CN` is used, Chinese Special options will be setup for good connectivity and experience against GFW. - - Default archive mirror is `https://chinanet.mirrors.ustc.edu.cn/debian`. - - Default security mirror is `https://chinanet.mirrors.ustc.edu.cn/debian-security`. + - Default archive mirror is `http://ftp.cn.debian.org/debian`. + - Default security mirror is `http://ftp.cn.debian.org/debian-security`. - Default time zone is `Asia/Shanghai`. - - Default NTP server is `ntp1.aliyun.com`. - - Default DNS is `1.2.4.8 119.29.29.29`. + - Default NTP server is `cn.ntp.org.cn`. + - Default DNS is `156.154.70.5 156.154.71.5`. - All custom settings will override above defaults. ## Step 3. Entering Debian Installer diff --git a/netboot.sh b/netboot.sh index 4671e6a..732237b 100644 --- a/netboot.sh +++ b/netboot.sh @@ -101,28 +101,28 @@ done case "$COUNTRY" in CN) - PROTO=${PROTO:-https} - HOST=${HOST:-chinanet.mirrors.ustc.edu.cn} + PROTO=${PROTO:-http} + HOST=${HOST:-ftp.cn.debian.org} TIME_ZONE=${TIME_ZONE:-Asia/Shanghai} - NTP=${NTP:-ntp1.aliyun.com} + NTP=${NTP:-cn.ntp.org.cn} SECURITY=${SECURITY:-true} - DNS=${DNS:-1.2.4.8 119.29.29.29} + DNS=${DNS:-156.154.70.5 156.154.71.5} esac COUNTRY=${COUNTRY:-US} -PROTO=${PROTO:-https} -HOST=${HOST:-dpvctowv9b08b.cloudfront.net} +PROTO=${PROTO:-http} +HOST=${HOST:-deb.debian.org} DIR=${DIR:-/debian} ARCH=$(dpkg --print-architecture) SUITE=${SUITE:-stretch} -ADMIN=${ADMIN:-ubuntu} +ADMIN=${ADMIN:-debian} TIME_ZONE=${TIME_ZONE:-UTC} -NTP=${NTP:-time.google.com} +NTP=${NTP:-pool.ntp.org} UPGRADE=${UPGRADE:-full-upgrade} -DNS=${DNS:-1.1.1.1 156.154.70.5 8.8.8.8} +DNS=${DNS:-8.8.8.8 8.8.4.4} if [ -z "$SECURITY" ]; then - SECURITY=https://dpvctowv9b08b.cloudfront.net/debian-security + SECURITY=http://security.debian.org/debian-security else if [ "$SECURITY" = true ]; then SECURITY=$PROTO://$HOST${DIR%/*}/debian-security @@ -192,8 +192,8 @@ if [ -n "$IP_ADDR" ]; then fi cat >> preseed.cfg << EOF -d-i netcfg/get_hostname string localhost -d-i netcfg/get_domain string localdomain +d-i netcfg/get_hostname string unassigned-hostname +d-i netcfg/get_domain string unassigned-domain EOF if [ -n "$FQDN" ]; then