From 1d85bfe302be69088977d9c69ea6f17ac748e499 Mon Sep 17 00:00:00 2001 From: "Simon L." Date: Tue, 17 Feb 2026 14:43:05 +0100 Subject: [PATCH] fix getting name of mastercontainer if a hash was found Signed-off-by: Simon L. --- Containers/mastercontainer/start.sh | 3 +++ php/src/Docker/DockerActionManager.php | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Containers/mastercontainer/start.sh b/Containers/mastercontainer/start.sh index ad1734f1..d9968c32 100644 --- a/Containers/mastercontainer/start.sh +++ b/Containers/mastercontainer/start.sh @@ -162,6 +162,9 @@ if ! sudo -E -u www-data docker ps --format "{{.Names}}" | grep -q "^nextcloud-a Using a different name is not supported since mastercontainer updates will not work in that case! If you are on docker swarm and try to run AIO, see https://github.com/nextcloud/all-in-one#can-i-run-this-with-docker-swarm" exit 1 +elif ! sudo -E -u www-data docker inspect nextcloud-aio-mastercontainer --format "{{.Config.Image}}" | grep -q '@'; then + print_red "It seems like you used a hash for the mastercontainer image tag. This is not supported!" + exit 1 elif ! sudo -E -u www-data docker volume ls --format "{{.Name}}" | grep -q "^nextcloud_aio_mastercontainer$"; then print_red "It seems like you did not give the mastercontainer volume the correct name? (The 'nextcloud_aio_mastercontainer' volume was not found.) Using a different name is not supported since the built-in backup solution will not work in that case!" diff --git a/php/src/Docker/DockerActionManager.php b/php/src/Docker/DockerActionManager.php index d6a52d93..6bdfc487 100644 --- a/php/src/Docker/DockerActionManager.php +++ b/php/src/Docker/DockerActionManager.php @@ -649,8 +649,8 @@ readonly class DockerActionManager { if (count($imageNameArray) === 2) { $imageName = $imageNameArray[0]; } else { - error_log("No tag was found when getting the current channel. You probably did not follow the documentation correctly. Changing the imageName to the default " . $output['Config']['Image']); - $imageName = $output['Config']['Image']; + error_log("Unexpected image name was found when getting the current image name of the mastercontainer. You probably did not follow the documentation correctly. Changing the image name to the default 'ghcr.io/nextcloud-releases/all-in-one'."); + $imageName = 'ghcr.io/nextcloud-releases/all-in-one'; } apcu_add($cacheKey, $imageName); return $imageName;