mirror of
https://github.com/bin456789/reinstall.git
synced 2025-12-10 07:28:56 +08:00
debian: 国内使用清华源
This commit is contained in:
@ -67,8 +67,8 @@ d-i finish-install/reboot_in_progress note
|
||||
|
||||
# B.5.1. 安装过程中运行用户命令
|
||||
d-i preseed/early_command string \
|
||||
wget http://www.cloudflare.com/cdn-cgi/trace -O- | grep -x 'loc=CN' && hostname=ftp.cn.debian.org || hostname=deb.debian.org; \
|
||||
debconf-set mirror/http/hostname $hostname
|
||||
hostname="$(grep -o 'extra\.deb_hostname=[^ ]*' /proc/cmdline | cut -d= -f2)"; \
|
||||
debconf-set mirror/http/hostname "$hostname"
|
||||
|
||||
d-i partman/early_command string \
|
||||
debconf-set partman-auto/disk "$(list-devices disk | head -n1)"; \
|
||||
|
||||
Reference in New Issue
Block a user