mirror of
https://github.com/YunoHost-Apps/gotify_ynh.git
synced 2024-09-03 20:36:26 +02:00
better permissions
This commit is contained in:
parent
3bc2f1fce7
commit
efbec554c0
4 changed files with 10 additions and 8 deletions
|
@ -6,7 +6,7 @@
|
|||
"en": "A simple server for sending and receiving messages.",
|
||||
"fr": "Un simple serveur pour envoyer et recevoir des messages."
|
||||
},
|
||||
"version": "2.0.16~ynh1",
|
||||
"version": "2.0.16~ynh2",
|
||||
"url": "http://gotify.net",
|
||||
"license": "MIT",
|
||||
"maintainer": {
|
||||
|
|
|
@ -137,12 +137,10 @@ ynh_store_file_checksum "$final_path/config.yml"
|
|||
#=================================================
|
||||
|
||||
# Set permissions to app files
|
||||
chown -R root: $final_path
|
||||
chown -R root:$app $final_path
|
||||
mkdir $final_path/data
|
||||
chown -R root:$app $final_path/*
|
||||
chmod -R 550 $final_path/*
|
||||
chown $app $final_path/data
|
||||
chmod 770 $final_path/data
|
||||
chown -R $app: $final_path/data/
|
||||
chmod o-rwx $final_path/ -R
|
||||
|
||||
#=================================================
|
||||
# ADVERTISE SERVICE IN ADMIN PANEL
|
||||
|
|
|
@ -76,8 +76,10 @@ ynh_system_user_create $app
|
|||
#=================================================
|
||||
|
||||
# Restore permissions on app files
|
||||
chown -R root: $final_path
|
||||
chown -R root:$app $final_path
|
||||
mkdir $final_path/data
|
||||
chown -R $app: $final_path/data/
|
||||
chmod o-rwx $final_path/ -R
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC RESTORATION
|
||||
|
|
|
@ -138,7 +138,9 @@ ynh_add_systemd_config
|
|||
#=================================================
|
||||
|
||||
# Set permissions on app files
|
||||
chown -R root: $final_path
|
||||
chown -R root:$app $final_path/
|
||||
chown -R $app: $final_path/data/
|
||||
chmod o-rwx $final_path/ -R
|
||||
|
||||
# If data directory doesn't exists
|
||||
if [ -z $final_path/data ]; then
|
||||
|
|
Loading…
Add table
Reference in a new issue