Skip to content

Commit 6667035

Browse files
authored
check php version
Signed-off-by: Daniel Hansson <[email protected]>
1 parent 9a32c86 commit 6667035

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

nextcloud_update.sh

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1000,6 +1000,21 @@ If you need support, please visit https://shop.hanssonit.se/product/upgrade-php-
10001000
fi
10011001
fi
10021002

1003+
# Check if PHP version is compatible with $NCVERSION
1004+
# https://github.com/nextcloud/server/issues/29258
1005+
PHP_VER=82
1006+
NC_VER=32
1007+
if [ "${NCVERSION%%.*}" -ge "$NC_VER" ]
1008+
then
1009+
if [ "$(php -v | head -n 1 | cut -d " " -f 2 | cut -c 1,3)" -lt "$PHP_VER" ]
1010+
then
1011+
msg_box "Your PHP version isn't compatible with the new version of Nextcloud. Please upgrade your PHP stack and try again.
1012+
1013+
If you need support, please visit https://shop.hanssonit.se/product/upgrade-php-version-including-dependencies/"
1014+
exit
1015+
fi
1016+
fi
1017+
10031018
# Upgrade Nextcloud
10041019
if ! site_200 "$NCREPO"
10051020
then

0 commit comments

Comments
 (0)