diff --git a/scripts/install b/scripts/install index b82edf5..04b3ba1 100755 --- a/scripts/install +++ b/scripts/install @@ -80,12 +80,16 @@ ynh_add_systemd_config #================================================= # GENERIC FINALIZATION #================================================= -# SETUP LOGROTATE +# LOGROTATE #================================================= -ynh_script_progression --message="Configuring log rotation..." +ynh_script_progression --message="Configuring logrotate to manage application logfiles" --weight=1 # Use logrotate to manage application logfile(s) -ynh_use_logrotate +ynh_use_logrotate --specific_user=$app +touch /var/log/$app/$app.log +touch /var/log/$app/${app}_workers.log +touch /var/log/$app/gunicorn.log +chown -R $app:www-data /var/log/$app/ #================================================= # INTEGRATE SERVICE IN YUNOHOST diff --git a/scripts/restore b/scripts/restore index a8a340a..f9c08fd 100755 --- a/scripts/restore +++ b/scripts/restore @@ -42,8 +42,7 @@ ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./ #================================================= # RESTORE SYSTEM CONFIGURATIONS #================================================= -# RESTORE THE PHP-FPM CONFIGURATION -#================================================= + ynh_script_progression --message="Restoring system configurations related to $app..." --weight=1 ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" diff --git a/scripts/upgrade b/scripts/upgrade index 34cd618..5764f12 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -59,12 +59,16 @@ ynh_add_systemd_config #================================================= # GENERIC FINALIZATION #================================================= -# SETUP LOGROTATE +# LOGROTATE #================================================= -ynh_script_progression --message="Configuring log rotation..." +ynh_script_progression --message="Configuring logrotate to manage application logfiles" --weight=1 # Use logrotate to manage application logfile(s) -ynh_use_logrotate +ynh_use_logrotate --specific_user=$app +touch /var/log/$app/$app.log +touch /var/log/$app/${app}_workers.log +touch /var/log/$app/gunicorn.log +chown -R $app:www-data /var/log/$app/ #================================================= # INTEGRATE SERVICE IN YUNOHOST