mirror of
https://github.com/YunoHost-Apps/nextcloud_ynh.git
synced 2024-09-03 19:55:57 +02:00
Merge 8b3220ef8c
into 46bffb0797
This commit is contained in:
commit
c813633bdd
5 changed files with 5 additions and 6 deletions
|
@ -3,4 +3,4 @@
|
|||
user="$1"
|
||||
app="$(basename $0 | cut -d- -f 2-)" # Extract the app name from the script name, which is supposed to be something like "50-app_id"
|
||||
|
||||
setfacl --modify g:$app:rwx /home/$user
|
||||
setfacl --recursive --modify g:$app:rwX,d:g:$app:rwX /home/$user
|
||||
|
|
|
@ -155,7 +155,7 @@ then
|
|||
create_external_storage "/home/\$user" "Home"
|
||||
# Iterate over users to extend their home folder permissions
|
||||
for u in $(ynh_user_list); do
|
||||
setfacl --modify g:$app:rwx "/home/$u" || true
|
||||
setfacl --recursive --modify g:$app:rwX,d:g:$app:rwX "/home/$u" || true
|
||||
done
|
||||
fi
|
||||
|
||||
|
|
|
@ -37,7 +37,7 @@ ynh_secure_remove --file="/etc/cron.d/$app"
|
|||
for path in /home/*; do
|
||||
# Clean ACL in every directories in /home, except those which start with 'yunohost.'
|
||||
[[ ! $path == /home/yunohost.* ]] \
|
||||
&& setfacl --remove g:$app -- "$path" 2>&1
|
||||
&& setfacl --recursive --remove g:$app,d:g:$app -- "$path" 2>&1
|
||||
done
|
||||
|
||||
#=================================================
|
||||
|
|
|
@ -93,8 +93,7 @@ chmod 750 $install_dir
|
|||
# Iterate over users to extend their home folder permissions - for the external
|
||||
# storage plugin usage - and create relevant Nextcloud directories
|
||||
for u in $(ynh_user_list); do
|
||||
mkdir -p "$data_dir/$u"
|
||||
setfacl --modify g:$app:rwx "/home/$u" || true
|
||||
setfacl --recursive --modify g:$app:rwX,d:g:$app:rwX "/home/$u" || true
|
||||
done
|
||||
|
||||
#=================================================
|
||||
|
|
|
@ -311,7 +311,7 @@ then
|
|||
|| create_external_storage "/home/\$user" "Home"
|
||||
# Iterate over users to extend their home folder permissions
|
||||
for u in $(ynh_user_list); do
|
||||
setfacl --modify g:$app:rwx "/home/$u" || true
|
||||
setfacl --recursive --modify g:$app:rwX,d:g:$app:rwX "/home/$u" || true
|
||||
done
|
||||
fi
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue