mirror of
https://github.com/YunoHost-Apps/bozon_ynh.git
synced 2024-09-03 18:16:09 +02:00
Enforce permissions
This commit is contained in:
parent
9925d9c48a
commit
c3e9b2543b
2 changed files with 9 additions and 7 deletions
|
@ -74,9 +74,10 @@ sudo ln -s "$data_path/uploads" "$final_path/uploads"
|
|||
sudo ln -s "$data_path/thumbs" "$final_path/thumbs"
|
||||
|
||||
# set permissions
|
||||
sudo find "$final_path" -type f | xargs sudo chmod 0644
|
||||
sudo find "$final_path" -type d | xargs sudo chmod 0755
|
||||
sudo find "$data_path" -type d | xargs sudo chmod 0755
|
||||
sudo find "$final_path" -type f | xargs sudo chmod 0640
|
||||
sudo find "$final_path" -type d | xargs sudo chmod 0750
|
||||
sudo find "$data_path" -type d | xargs sudo chmod 0750
|
||||
sudo chown -R "$root":"$app" "$final_path"
|
||||
sudo chown -R "$app": "$final_path/private"
|
||||
sudo chown -R "$app": "$data_path/uploads"
|
||||
sudo chown -R "$app": "$data_path/thumbs"
|
||||
|
|
|
@ -74,10 +74,11 @@ sudo cp -a "$TMPDIR/." "$final_path"
|
|||
sudo rm -R "$TMPDIR"
|
||||
|
||||
# set permissions
|
||||
sudo find "$final_path" -type f | xargs sudo chmod 0644
|
||||
sudo find "$final_path" -type d | xargs sudo chmod 0755
|
||||
sudo find "$data_path" -type f | xargs sudo chmod 0645
|
||||
sudo find "$data_path" -type d | xargs sudo chmod 0755
|
||||
sudo find "$final_path" -type f | xargs sudo chmod 0640
|
||||
sudo find "$final_path" -type d | xargs sudo chmod 0750
|
||||
sudo find "$data_path" -type f | xargs sudo chmod 0640
|
||||
sudo find "$data_path" -type d | xargs sudo chmod 0750
|
||||
sudo chown -R "$root":"$app" "$final_path"
|
||||
sudo chown -R "$app": "$final_path/private"
|
||||
sudo chown -R "$app": "$data_path/uploads"
|
||||
sudo chown -R "$app": "$data_path/thumbs"
|
||||
|
|
Loading…
Reference in a new issue