From a36eaf7e9ab081f3c05e13b7eb8254a96edeb970 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=80=97=E5=AD=90?= Date: Thu, 13 Jun 2024 02:38:29 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=87=AA=E5=90=AF=E5=8A=A8podman-resta?= =?UTF-8?q?rt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/podman/install.sh | 2 ++ scripts/podman/uninstall.sh | 3 +++ scripts/update_panel.sh | 10 +++++++--- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/scripts/podman/install.sh b/scripts/podman/install.sh index 4abc9c65..837f6875 100644 --- a/scripts/podman/install.sh +++ b/scripts/podman/install.sh @@ -35,7 +35,9 @@ else fi systemctl enable podman +systemctl enable podman-restart systemctl start podman +systemctl start podman-restart panel writePlugin podman ${podmanVersion} echo -e ${HR} diff --git a/scripts/podman/uninstall.sh b/scripts/podman/uninstall.sh index 39249f19..29d142e3 100644 --- a/scripts/podman/uninstall.sh +++ b/scripts/podman/uninstall.sh @@ -21,7 +21,10 @@ along with this program. If not, see . HR="+----------------------------------------------------" OS=$(source /etc/os-release && { [[ "$ID" == "debian" ]] && echo "debian"; } || { [[ "$ID" == "centos" ]] || [[ "$ID" == "rhel" ]] || [[ "$ID" == "rocky" ]] || [[ "$ID" == "almalinux" ]] && echo "centos"; } || echo "unknown") + +systemctl stop podman-restart systemctl stop podman +systemctl disable podman-restart systemctl disable podman if [ "${OS}" == "centos" ]; then diff --git a/scripts/update_panel.sh b/scripts/update_panel.sh index fc4e5da4..4e514566 100644 --- a/scripts/update_panel.sh +++ b/scripts/update_panel.sh @@ -106,11 +106,15 @@ if version_lt "$oldVersion" "2.2.4"; then fi fi -if version_lt "$oldVersion" "2.2.6"; then - echo "更新面板到 v2.2.6 ..." - echo "Update panel to v2.2.6 ..." +if version_lt "$oldVersion" "2.2.9"; then + echo "更新面板到 v2.2.9 ..." + echo "Update panel to v2.2.9 ..." if [ -f "/usr/bin/podman" ]; then panel writePlugin podman 4.0.0 + systemctl enable podman + systemctl enable podman-restart + systemctl start podman + systemctl start podman-restart fi fi