From 0597b4e7c22931d3133b423bc1b3186f879ddbcd Mon Sep 17 00:00:00 2001 From: fab Date: Wed, 14 Aug 2024 14:11:17 +0200 Subject: [PATCH] Update uninstall.sh --- uninstall.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/uninstall.sh b/uninstall.sh index 2653c09..5b90ad3 100644 --- a/uninstall.sh +++ b/uninstall.sh @@ -9,6 +9,10 @@ LOG_PATH="/var/log/lxc_autoscale.log" BACKUP_DIR="/var/lib/lxc_autoscale/backups" LOCK_FILE="/var/lock/lxc_autoscale.lock" +# Dirty workaround to force existing process to terminate +echo "⚠️ Dirty workaround to force existing process to terminate.." +kill -9 $(ps aux | grep lxc_autoscale | grep -v grep | awk '{print $2}') + # Function to kill the process if it's running kill_process() { local pids=$(pgrep -f "$INSTALL_PATH")