Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/nextcloudpi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authornachoparker <nacho@ownyourbits.com>2018-05-03 11:52:26 +0300
committernachoparker <nacho@ownyourbits.com>2018-05-03 11:52:38 +0300
commit28d2332eb9deace56c4f5aec0c087806aead31aa (patch)
treebd91f23490e240a8cd9bacc40cc201e875498277 /etc
parent73bc22ad7e3b427ddf1231e41ab0fbebb6c114d8 (diff)
nc-datadir: avoid using occ for faster executionv0.54.3
Diffstat (limited to 'etc')
-rw-r--r--etc/ncp-config.d/nc-datadir.sh3
1 files changed, 1 insertions, 2 deletions
diff --git a/etc/ncp-config.d/nc-datadir.sh b/etc/ncp-config.d/nc-datadir.sh
index b03bc5ad..63e96c25 100644
--- a/etc/ncp-config.d/nc-datadir.sh
+++ b/etc/ncp-config.d/nc-datadir.sh
@@ -23,8 +23,7 @@ because they do not provide a compatible user/permissions system"
is_active()
{
local SRCDIR
- [[ "$( id -u )" != 33 ]] && local SUDO="sudo -u www-data"
- SRCDIR=$( $SUDO php /var/www/nextcloud/occ config:system:get datadirectory ) || return 1;
+ SRCDIR="$( grep datadirectory /var/www/nextcloud/config/config.php | awk '{ print $3 }' | grep -oP "[^']*[^']" | head -1 )" || return 1
[[ "$SRCDIR" != "/var/www/nextcloud/data" ]]
}