From b38b103b9f52d29029b1f0be3380ab4518703f3f Mon Sep 17 00:00:00 2001 From: tituspijean Date: Wed, 1 May 2024 22:05:09 +0200 Subject: [PATCH] No more conditions on database --- scripts/backup | 6 ++---- scripts/restore | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/scripts/backup b/scripts/backup index d94a247..65412d5 100755 --- a/scripts/backup +++ b/scripts/backup @@ -44,11 +44,9 @@ ynh_backup --src_path="/etc/gemserv/config.d/$domain.toml" #================================================= # BACKUP THE MYSQL DATABASE #================================================= +ynh_print_info --message="Backing up the MySQL database..." -if [ "$with_mysql" -eq 1 ]; then - ynh_print_info --message="Backing up the MySQL database..." - ynh_mysql_dump_db --database="$db_name" > db.sql -fi +ynh_mysql_dump_db --database="$db_name" > db.sql #================================================= # END OF SCRIPT diff --git a/scripts/restore b/scripts/restore index 4ee4410..c231ed3 100755 --- a/scripts/restore +++ b/scripts/restore @@ -44,11 +44,9 @@ setfacl -m g:"gemserv":r-x "$install_dir" #================================================= # RESTORE THE MYSQL DATABASE #================================================= -if [ "$with_mysql" -eq 1 ]; then - ynh_script_progression --message="Restoring the MySQL database..." --weight=1 +ynh_script_progression --message="Restoring the MySQL database..." --weight=1 - ynh_mysql_connect_as --user="$db_user" --password="$db_pwd" --database="$db_name" < ./db.sql -fi +ynh_mysql_connect_as --user="$db_user" --password="$db_pwd" --database="$db_name" < ./db.sql #================================================= # RESTORE SYSTEM CONFIGURATIONS