From 403f8befeca3916cd3e51826b61e8ca53f835ee7 Mon Sep 17 00:00:00 2001 From: MacRimi Date: Tue, 8 Apr 2025 21:34:44 +0200 Subject: [PATCH] Update disk-passthrough_ct.sh --- scripts/disk-passthrough_ct.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/disk-passthrough_ct.sh b/scripts/disk-passthrough_ct.sh index deb96ca..df9f81d 100644 --- a/scripts/disk-passthrough_ct.sh +++ b/scripts/disk-passthrough_ct.sh @@ -222,7 +222,6 @@ while read -r DISK; do REAL_PATH=$(readlink -f "$DISK") CONFIG_DATA=$(grep -vE '^\s*#' /etc/pve/qemu-server/*.conf /etc/pve/lxc/*.conf 2>/dev/null) - if grep -Fq "$REAL_PATH" <<< "$CONFIG_DATA"; then USED_BY="⚠ $(translate "In use")" else @@ -252,7 +251,7 @@ while read -r DISK; do SHOW_DISK=false fi - if pct config "$CTID" | grep -q "$DISK"; then + if pct config "$CTID" | grep -vE '^\s*#|^description:' | grep -q "$DISK"; then SHOW_DISK=false fi