diff options
-rwxr-xr-x | bin/ncp-update-nc | 2 | ||||
-rw-r--r-- | bin/ncp/BACKUPS/nc-restore.sh | 2 | ||||
-rw-r--r-- | updates/1.40.0.sh | 2 |
3 files changed, 4 insertions, 2 deletions
diff --git a/bin/ncp-update-nc b/bin/ncp-update-nc index 05fa7190..1916c9dd 100755 --- a/bin/ncp-update-nc +++ b/bin/ncp-update-nc @@ -33,7 +33,7 @@ DATADIR="$( grep datadirectory nextcloud/config/config.php | awk '{ print $3 }' [[ -d /var/www/nextcloud-old ]] && { echo "Nextcloud backup directory found. Interrupted or already running installation?"; exit 1; } [[ -d /var/www/nextcloud ]] || { echo "Nextcloud directory not found" ; exit 1; } [[ -d "$DATADIR" ]] || { echo "Nextcloud data directory not found" ; exit 1; } -[[ "$(stat -fc%T "$BASEDIR")" == "btrfs" ]] && { echo "BTRFS not supported" ; exit 1; } +grep -q "btrfs" <(stat -fc%T "$BASEDIR") && { echo "BTRFS not supported" ; exit 1; } # check version #################### diff --git a/bin/ncp/BACKUPS/nc-restore.sh b/bin/ncp/BACKUPS/nc-restore.sh index f78f1a33..0ada9950 100644 --- a/bin/ncp/BACKUPS/nc-restore.sh +++ b/bin/ncp/BACKUPS/nc-restore.sh @@ -111,7 +111,7 @@ if [[ $( ls "$TMPDIR" | wc -l ) -eq $NUMFILES ]]; then echo "restore datadir to $DATADIR..." mkdir -p "$DATADIR" - [[ "$( stat -fc%T "$DATADIR" )" == "btrfs" ]] && which btrfs &>/dev/null && { + grep -q "btrfs" <(stat -fc%T "$DATADIR") && which btrfs &>/dev/null && { rmdir "$DATADIR" || exit 1 btrfs subvolume create "$DATADIR" || exit 1 } diff --git a/updates/1.40.0.sh b/updates/1.40.0.sh index 43f56cc3..118729cf 100644 --- a/updates/1.40.0.sh +++ b/updates/1.40.0.sh @@ -8,6 +8,8 @@ source /usr/local/etc/library.sh # sets NCLATESTVER PHPVER RELEASE # all images +install_app nc-restore + # docker images only [[ -f /.docker-image ]] && { : |