This commit is contained in:
hl committed 2026-01-10 09:25:45 +08:00
1 parent bc9ede9bf9
commit e32cdc1b47
1 file changed
+13 -5
+13 -5
View File
@@ -26,6 +26,13 @@ choose_sites(){
DOCKER_PGP=https://mirrors.cernet.edu.cn/docker-ce/linux/debian/gpg
PVE_URL=https://mirrors.cernet.edu.cn/proxmox/debian/pve
;;
2)
MIRROR_URL=https://mirrors.aliyun.com/debian/
SEC_URL=https://mirrors.aliyun.com/debian-security
DOCKER_URL=https://mirrors.aliyun.com/docker-ce/linux/debian
DOCKER_PGP=https://mirrors.aliyun.com/docker-ce/linux/debian/gpg
PVE_URL=https://mirrors.cernet.edu.cn/proxmox/debian/pve
;;
*)
MIRROR_URL=https://deb.debian.org/debian/
SEC_URL=https://security.debian.org/debian-security
@@ -99,22 +106,22 @@ Architectures: $OS_ARCH
fi
}
config(){
setup(){
apt update
apt list nala ca-certificates curl gnupg gpg lsb-release git zsh | awk -F'/' '/\// {print $1}' | xargs -r apt install --no-install-recommends -y
set_pkg_source
apt update
$AWD/configure.sh
}
usage(){
echo "Usage: $0 [OPTIONS]";
echo "OPTIONS:";
echo " -f <PACKAGES> package list file (default: $PKG_BASE)";
echo " -c config only";
echo " -s setup only";
echo " -m <CHOICE> apt mirror source";
echo " * official"
echo " 1 cernet (default)"
echo " 2 aliyun"
}
PKG_BASE="$AWD/packages-base"
@@ -125,7 +132,7 @@ while getopts ":f:cm:" OPT; do
f)
PKG_BASE=$OPTARG;
;;
c)
s)
DO_INSTALL=false;
;;
m)
@@ -138,7 +145,8 @@ while getopts ":f:cm:" OPT; do
esac;
done;
config
setup
if $DO_INSTALL; then
$AWD/configure.sh
$AWD/install.sh $PKG_BASE
fi