From 7a1c9fae369acd95577c0b2c0202268120c10c49 Mon Sep 17 00:00:00 2001 From: fscarmen <62703343+fscarmen@users.noreply.github.com> Date: Wed, 25 May 2022 13:03:19 +0800 Subject: [PATCH] Update menu.sh --- menu.sh | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-) diff --git a/menu.sh b/menu.sh index 7a8cd7b..ffd1c66 100644 --- a/menu.sh +++ b/menu.sh @@ -1569,13 +1569,10 @@ proxy(){ if [[ $SYSTEM = CentOS ]]; then wget https://github.com/fscarmen/warp/raw/main/Client/Client_CentOS_8.rpm case "$(expr "$SYS" : '.*\s\([0-9]\{1,\}\)\.*')" in - 7 ) #rpm -ivh https://pkg.cloudflareclient.com/cloudflare-release-el8.rpm >/dev/null 2>&1 - # CentOS 7,需要用 Cloudflare CentOS 8 的库以安装 Client,并在线编译升级 C 运行库 Glibc 2.28 + 7 ) # CentOS 7,需要用 Cloudflare CentOS 8 的库以安装 Client,并在线编译升级 C 运行库 Glibc 2.28 { wget -O /usr/bin/make https://github.com/fscarmen/warp/releases/download/Glibc/make wget https://github.com/fscarmen/warp/releases/download/Glibc/glibc-2.28.tar.gz tar -xzvf glibc-2.28.tar.gz; }& - #sed -i "s/\$releasever/8/g" /etc/yum.repos.d/cloudflare.repo - #${PACKAGE_UPDATE[int]}; ${PACKAGE_INSTALL[int]} cloudflare-warp rpm -ivh Client_CentOS_8.rpm ${PACKAGE_INSTALL[int]} gcc bison make centos-release-scl ${PACKAGE_INSTALL[int]} devtoolset-8-gcc devtoolset-8-gcc-c++ devtoolset-8-binutils @@ -1587,31 +1584,16 @@ proxy(){ cd ../.. rm -rf glibc-2.28*;; - 8 ) #rpm -ivh Client_CentOS_8.rpm - #${PACKAGE_UPDATE[int]} - #${PACKAGE_INSTALL[int]} cloudflare-warp;; - rpm -ivh Client_CentOS_8.rpm;; - - 9 ) # CentOS stream 9,截止到 2022年5月20日,官方库仍未支持。在 CloudFlare 官网下载 rpm 文件本地安装 - ${PACKAGE_INSTALL[int]} install desktop-file-utils - #CLOUDFLARE_WARP_RPM='cloudflare_warp_2022_4_235_1_x86_64_aa859896da.rpm' - #wget https://pkg.cloudflareclient.com/uploads/$CLOUDFLARE_WARP_RPM - #rpm -ivh $CLOUDFLARE_WARP_RPM - #rm -f $CLOUDFLARE_WARP_RPM + 8|9 ) ! type -p desktop-file-install && ${PACKAGE_INSTALL[int]} install desktop-file-utils rpm -ivh Client_CentOS_8.rpm;; esac rm -f Client_CentOS_8.rpm else { wget --no-check-certificate $CDN https://github.com/fscarmen/warp/raw/main/Client/Client_${SYSTEM}_${VERSION_ID}.deb; }& - #[[ $SYSTEM = Debian && ! $(type -P gpg 2>/dev/null) ]] && ${PACKAGE_INSTALL[int]} gnupg [[ $SYSTEM = Debian && ! $(apt list 2>/dev/null | grep apt-transport-https) =~ installed ]] && ${PACKAGE_INSTALL[int]} apt-transport-https # 如为 Ubuntu 22.04(jammy) 由于官方库暂未支持,故欺骗为20.04(focal) -# CODENAME=$(cat /etc/os-release | grep -i VERSION_CODENAME | sed s/.*=//g | sed "s/jammy/focal/") -# curl https://pkg.cloudflareclient.com/pubkey.gpg | gpg --yes --dearmor --output /usr/share/keyrings/cloudflare-warp-archive-keyring.gpg -# echo "deb [arch=amd64 signed-by=/usr/share/keyrings/cloudflare-warp-archive-keyring.gpg] https://pkg.cloudflareclient.com/ $CODENAME main" | tee /etc/apt/sources.list.d/cloudflare-client.list wait dpkg -i Client_${SYSTEM}_${VERSION_ID}.deb >/dev/null 2>&1 -# ${PACKAGE_INSTALL[int]} desktop-file-utils gnupg2 libjansson4 libnftables1 nftables ${PACKAGE_INSTALL[int]} -f dpkg -i Client_${SYSTEM}_${VERSION_ID}.deb rm -f Client_${SYSTEM}_${VERSION_ID}.deb