From 055f77fc92c919e8172ac969cca7e8efcfe80a1d Mon Sep 17 00:00:00 2001 From: yalh76 Date: Thu, 29 Apr 2021 21:08:10 +0200 Subject: [PATCH] More script progression --- scripts/install | 1 + scripts/remove | 1 + scripts/restore | 4 ++++ scripts/upgrade | 1 + 4 files changed, 7 insertions(+) diff --git a/scripts/install b/scripts/install index 9957a4b..0c48d6c 100755 --- a/scripts/install +++ b/scripts/install @@ -201,6 +201,7 @@ ynh_add_fpm_config #================================================= # ADD A CONFIGURATION #================================================= +ynh_script_progression --message="Adding a configuration file..." --time --weight=1 ### You can add specific configuration files. ### diff --git a/scripts/remove b/scripts/remove index 5056b4f..367e0c5 100755 --- a/scripts/remove +++ b/scripts/remove @@ -114,6 +114,7 @@ ynh_remove_fail2ban_config #================================================= # REMOVE VARIOUS FILES #================================================= +ynh_script_progression --message="Removing various files..." --time --weight=1 # Remove a cron file ynh_secure_remove --file="/etc/cron.d/$app" diff --git a/scripts/restore b/scripts/restore index 7b40168..b0b605e 100755 --- a/scripts/restore +++ b/scripts/restore @@ -50,6 +50,7 @@ test ! -d $final_path \ #================================================= # RESTORE THE NGINX CONFIGURATION #================================================= +ynh_script_progression --message="Restoring the NGINX configuration..." --time --weight=1 ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" @@ -81,6 +82,7 @@ chown -R $app:www-data "$final_path" #================================================= # RESTORE THE PHP-FPM CONFIGURATION #================================================= +ynh_script_progression --message="Restoring the PHP-FPM configuration..." --time --weight=1 ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf" @@ -115,6 +117,7 @@ ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./ #================================================= # RESTORE VARIOUS FILES #================================================= +ynh_script_progression --message="Restoring various files..." --time --weight=1 ynh_restore_file --origin_path="/etc/cron.d/$app" @@ -145,6 +148,7 @@ ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$ap #================================================= # RESTORE THE LOGROTATE CONFIGURATION #================================================= +ynh_script_progression --message="Restoring the logrotate configuration..." --time --weight=1 ynh_restore_file --origin_path="/etc/logrotate.d/$app" diff --git a/scripts/upgrade b/scripts/upgrade index 7850fb0..313a853 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -163,6 +163,7 @@ ynh_add_fpm_config #================================================= # UPDATE A CONFIG FILE #================================================= +ynh_script_progression --message="Updating a configuration file..." --time --weight=1 ### Same as during install ###