From 98078cbe0a36bb4dcf8b5ba0e2dee92a5a8ee0d5 Mon Sep 17 00:00:00 2001 From: Simon L Date: Thu, 2 Mar 2023 09:12:07 +0100 Subject: [PATCH] improve the volume and container name check Signed-off-by: Simon L --- Containers/mastercontainer/start.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Containers/mastercontainer/start.sh b/Containers/mastercontainer/start.sh index fbcf7c72..6a13488f 100644 --- a/Containers/mastercontainer/start.sh +++ b/Containers/mastercontainer/start.sh @@ -77,11 +77,11 @@ elif echo "$STORAGE_DRIVER" | grep -q fuse-overlayfs; then fi # Check if startup command was executed correctly -if ! sudo -u www-data docker ps | grep -q "nextcloud-aio-mastercontainer"; then +if ! sudo -u www-data docker ps --format "{{.Name}}" | grep -q "^nextcloud-aio-mastercontainer$"; then echo "It seems like you did not give the mastercontainer the correct name? Using a different name is not supported!" exit 1 -elif ! sudo -u www-data docker volume ls | grep -q "nextcloud_aio_mastercontainer"; then +elif ! sudo -u www-data docker volume ls --format "{{.Name}}" | grep -q "^nextcloud_aio_mastercontainer$"; then echo "It seems like you did not give the mastercontainer volume the correct name? Using a different name is not supported!" exit 1