Update install.sh

This commit is contained in:
qiaofeng1227 2023-05-22 17:12:08 +08:00 committed by GitHub
parent 4d0d9c4d50
commit 19e190fc7a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -207,9 +207,9 @@ if [ "${os_type}" == 'Debian' ]; then
fi fi
if [ "${os_type}" == 'Ubuntu' ]; then if [ "${os_type}" == 'Ubuntu' ]; then
if grep -q "^#.*deb http://mirrors.cloud.aliyuncs.com/ubuntu.*backports" /etc/apt/sources.list; then if grep -q "^#.*deb http://mirrors.tencentyun.com/ubuntu.*backports" /etc/apt/sources.list; then
echo "Add backports deb ..." echo "Add backports deb ..."
sudo sed -i 's/^#\(.*deb http:\/\/mirrors.cloud.aliyuncs.com\/ubuntu.*backports.*\)/\1/' /etc/apt/sources.list sudo sed -i 's/^#\(.*deb http:\/\/mirrors.tencentyun.com\/ubuntu.*backports.*\)/\1/' /etc/apt/sources.list
apt update apt update
fi fi
VERSION_CODENAME=$(cat /etc/os-release |grep VERSION_CODENAME|cut -f2 -d"=") VERSION_CODENAME=$(cat /etc/os-release |grep VERSION_CODENAME|cut -f2 -d"=")