From 0d8233c1a08a994c9b883190f519a0b5a68ed06e Mon Sep 17 00:00:00 2001 From: spiritlhl <103393591+spiritLHLS@users.noreply.github.com> Date: Sat, 24 Jun 2023 14:56:03 +0000 Subject: [PATCH] =?UTF-8?q?=E9=80=82=E9=85=8Dpve8.0=E7=9A=84=E9=9D=9E?= =?UTF-8?q?=E8=AE=A2=E9=98=85=E7=94=A8=E6=88=B7=E5=BC=B9=E7=AA=97=E8=BF=9B?= =?UTF-8?q?=E8=A1=8C=E5=88=A0=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 1 + scripts/build_backend.sh | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8351747..5270c6c 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,7 @@ - 更新Debian12安装的PVE版本为stable - 修复部分机器ifconfig命令不存在的问题 - 适配部分机器ipv6网络是SLAAC动态分配的情况 +- 适配pve8.0的非订阅用户弹窗进行删除 [更新日志](CHANGELOG.md) diff --git a/scripts/build_backend.sh b/scripts/build_backend.sh index 90b0dd6..8a02b8b 100644 --- a/scripts/build_backend.sh +++ b/scripts/build_backend.sh @@ -35,7 +35,11 @@ fi # 移除订阅弹窗 pve_version=$(dpkg-query -f '${Version}' -W proxmox-ve 2>/dev/null | cut -d'-' -f1) -if [[ "$pve_version" == 7.* ]]; then +if [[ "$pve_version" == 8.* ]]; then + # pve8.x + cp -rf /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js.bak + sed -Ezi.bak "s/(Ext.Msg.show\(\{\s+title: gettext\('No valid sub)/void\(\{ \/\/\1/g" /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js +elif [[ "$pve_version" == 7.* ]]; then # pve7.x cp -rf /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js.bak sed -Ezi.bak "s/(Ext.Msg.show\(\{\s+title: gettext\('No valid sub)/void\(\{ \/\/\1/g" /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js