mirror of
https://github.com/YunoHost-Apps/nodered_ynh.git
synced 2024-09-03 19:46:25 +02:00
Fix
This commit is contained in:
parent
db85648833
commit
56bafd98b0
3 changed files with 10 additions and 22 deletions
|
@ -20,7 +20,7 @@
|
|||
"email": "tituspijean@outlook.com"
|
||||
},
|
||||
"requirements": {
|
||||
"yunohost": ">= 4.1.7"
|
||||
"yunohost": ">= 4.2.0"
|
||||
},
|
||||
"multi_instance": true,
|
||||
"services": [
|
||||
|
|
|
@ -101,6 +101,10 @@ pushd $final_path
|
|||
ynh_exec_warn_less ynh_exec_as $app $ynh_node_load_PATH $ynh_npm install node-red-dashboard
|
||||
popd
|
||||
|
||||
chmod 750 "$final_path"
|
||||
chmod -R o-rwx "$final_path"
|
||||
chown -R $app:www-data "$final_path"
|
||||
|
||||
#=================================================
|
||||
# NGINX CONFIGURATION
|
||||
#=================================================
|
||||
|
@ -125,17 +129,6 @@ ynh_script_progression --message="Configuring a systemd service..." --weight=3
|
|||
# Create a dedicated systemd config
|
||||
ynh_add_systemd_config
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
#=================================================
|
||||
# SECURE FILES AND DIRECTORIES
|
||||
#=================================================
|
||||
|
||||
# Set permissions to app files
|
||||
chmod 750 "$final_path"
|
||||
chmod -R o-rwx "$final_path"
|
||||
chown -R $app: "$final_path"
|
||||
|
||||
#=================================================
|
||||
# SETUP LOGROTATE
|
||||
#=================================================
|
||||
|
|
|
@ -45,13 +45,6 @@ test ! -d $final_path \
|
|||
|
||||
ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
||||
|
||||
#=================================================
|
||||
# RESTORE THE APP MAIN DIR
|
||||
#=================================================
|
||||
ynh_script_progression --message="Restoring Node-RED main directory..." --weight=10
|
||||
|
||||
ynh_restore_file --origin_path="$final_path"
|
||||
|
||||
#=================================================
|
||||
# RECREATE THE DEDICATED USER
|
||||
#=================================================
|
||||
|
@ -61,13 +54,15 @@ ynh_script_progression --message="Recreating the dedicated system user..." --wei
|
|||
ynh_system_user_create --username=$app --home_dir=$final_path
|
||||
|
||||
#=================================================
|
||||
# RESTORE USER RIGHTS
|
||||
# RESTORE THE APP MAIN DIR
|
||||
#=================================================
|
||||
ynh_script_progression --message="Restoring Node-RED main directory..." --weight=10
|
||||
|
||||
ynh_restore_file --origin_path="$final_path"
|
||||
|
||||
# Restore permissions on app files
|
||||
chmod 750 "$final_path"
|
||||
chmod -R o-rwx "$final_path"
|
||||
chown -R $app: "$final_path"
|
||||
chown -R $app:www-data "$final_path"
|
||||
|
||||
# Create log directory and apply permissions
|
||||
mkdir -p /var/log/$app
|
||||
|
|
Loading…
Add table
Reference in a new issue