diff options
author | Daniel Hansson <github@hanssonit.se> | 2020-11-12 23:39:53 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-12 23:39:53 +0300 |
commit | 383a4e1c3e507ad1f9378c0faa1d499580bfb891 (patch) | |
tree | 30454cd6a77f4275300157be52956b59dc5af54d /static/setup_secure_permissions_nextcloud.sh | |
parent | 2187c5b13fe031dc19ed110b124b5a3205138902 (diff) |
put default SC rules in a single file (#1667)
Signed-off-by: enoch85 <github@hanssonit.se>
Diffstat (limited to 'static/setup_secure_permissions_nextcloud.sh')
-rw-r--r-- | static/setup_secure_permissions_nextcloud.sh | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/static/setup_secure_permissions_nextcloud.sh b/static/setup_secure_permissions_nextcloud.sh index 254896f6..2af5ab41 100644 --- a/static/setup_secure_permissions_nextcloud.sh +++ b/static/setup_secure_permissions_nextcloud.sh @@ -2,7 +2,6 @@ # T&M Hansson IT AB © - 2020, https://www.hanssonit.se/ -# shellcheck disable=2034,2059,2012 true SCRIPT_NAME="Setup Secure Permissions for Nextcloud" # shellcheck source=lib.sh @@ -67,7 +66,7 @@ then chown "${rootuser}":"${rootuser}" "${VMLOGS}"/update.log fi -if ! [ "$(ls -ld "${NCDATA}" | awk '{print$3$4}')" == "${htuser}""${htgroup}" ] +if stat -c "%U:%G" "$NCDATA"/* | grep -cv "${htuser}:${htgroup}" then chown -R "${htuser}":"${htgroup}" "${NCDATA}"/ fi |