diff --git a/.github/workflows/check-code-with-shellcheck.yml b/.github/workflows/check-code-with-shellcheck.yml index 0859829c..a5cab886 100644 --- a/.github/workflows/check-code-with-shellcheck.yml +++ b/.github/workflows/check-code-with-shellcheck.yml @@ -10,7 +10,7 @@ jobs: name: Github Actions runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Run Shellcheck uses: ludeeus/action-shellcheck@master with: diff --git a/.github/workflows/reviewdog.yml b/.github/workflows/reviewdog.yml index a58bdd06..85629c25 100644 --- a/.github/workflows/reviewdog.yml +++ b/.github/workflows/reviewdog.yml @@ -11,7 +11,7 @@ jobs: name: Shellcheck testing runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: shellcheck uses: reviewdog/action-shellcheck@v1 with: @@ -25,7 +25,7 @@ jobs: runs-on: ubuntu-latest steps: - name: spelling or typos - uses: actions/checkout@v4 + uses: actions/checkout@v5 - name: misspell uses: reviewdog/action-misspell@v1 with: diff --git a/nextcloud_update.sh b/nextcloud_update.sh index bb98f31a..684442cf 100644 --- a/nextcloud_update.sh +++ b/nextcloud_update.sh @@ -1000,6 +1000,21 @@ If you need support, please visit https://shop.hanssonit.se/product/upgrade-php- fi fi +# Check if PHP version is compatible with $NCVERSION +# https://github.com/nextcloud/server/issues/29258 +PHP_VER=82 +NC_VER=32 +if [ "${NCVERSION%%.*}" -ge "$NC_VER" ] +then + if [ "$(php -v | head -n 1 | cut -d " " -f 2 | cut -c 1,3)" -lt "$PHP_VER" ] + then +msg_box "Your PHP version isn't compatible with the new version of Nextcloud. Please upgrade your PHP stack and try again. + +If you need support, please visit https://shop.hanssonit.se/product/upgrade-php-version-including-dependencies/" + exit + fi +fi + # Upgrade Nextcloud if ! site_200 "$NCREPO" then diff --git a/not-supported/plexmediaserver.sh b/not-supported/plexmediaserver.sh index 9ec7a37e..760bfbd0 100644 --- a/not-supported/plexmediaserver.sh +++ b/not-supported/plexmediaserver.sh @@ -71,6 +71,10 @@ DIRECTORIES=$(find /mnt/ -mindepth 1 -maxdepth 2 -type d | grep -v "/mnt/ncdata" mapfile -t DIRECTORIES <<< "$DIRECTORIES" for directory in "${DIRECTORIES[@]}" do + # Open directory to make sure that it is accessible + ls "$directory" &>/dev/null + + # Continue with the logic if mountpoint -q "$directory" && [ "$(stat -c '%a' "$directory")" = "770" ] then if [ "$(stat -c '%U' "$directory")" = "www-data" ] && [ "$(stat -c '%G' "$directory")" = "www-data" ] diff --git a/not-supported/remotedesktop.sh b/not-supported/remotedesktop.sh index fb87911b..a20fad41 100644 --- a/not-supported/remotedesktop.sh +++ b/not-supported/remotedesktop.sh @@ -19,19 +19,19 @@ debug_mode # Check if root root_check +# Don't run this script as root user, because we will need the account +if [ -z "$UNIXUSER" ] +then + msg_box "Please don't run this script as pure root user!" + exit 1 +fi + # Check if xrdp is installed if ! is_this_installed xrdp then # Ask for installing install_popup "$SCRIPT_NAME" XRDP_INSTALL=1 - - # Don't run this script as root user, because we will need the account - if [ -z "$UNIXUSER" ] - then - msg_box "Please don't run this script as pure root user!" - exit 1 - fi # Check if gnome-session is installed if ! is_this_installed gnome-session diff --git a/not-supported/tpm2-unlock.sh b/not-supported/tpm2-unlock.sh index 936ccd32..6480afe9 100644 --- a/not-supported/tpm2-unlock.sh +++ b/not-supported/tpm2-unlock.sh @@ -99,10 +99,11 @@ GRUB_PASS="$(echo -e "$PASSWORD\n$PASSWORD" | grub-mkpasswd-pbkdf2 | grep -oP 'g if [ -n "${PASSWORD##grub.pbkdf2.sha512.10000.}" ] then cat << GRUB_CONF > /etc/grub.d/40_custom - +cat << EOF # Password-protect GRUB set superusers="grub" password_pbkdf2 grub $GRUB_PASS +EOF GRUB_CONF # Allow to run the default grub options without requiring the grub password if ! grep -q '^CLASS=.*--unrestricted"' /etc/grub.d/10_linux && grep -q '^CLASS=.*"$' /etc/grub.d/10_linux