From 12a9cb87a37fb79c4b8c85c8aa8fe24c95dbbe63 Mon Sep 17 00:00:00 2001 From: David Sterry Date: Mon, 13 Dec 2021 09:48:25 -0800 Subject: [PATCH] Simplify args, fix install speed and several scripts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Fix inneffectual args and startup timeouts (#26) * remove --time flags * add help on public/private question * Don't backup non-existent /etc/acropolis (#31) * don't test for things we can't do * add ynh_add_swap to backup, restore scripts, fix service names in upgrade (#34) Co-authored-by: Yunohost-Bot <> Co-authored-by: Éric Gaspar <46165813+ericgaspar@users.noreply.github.com> --- check_process | 6 +++--- scripts/backup | 9 +-------- scripts/restore | 1 + scripts/upgrade | 4 ++-- 4 files changed, 7 insertions(+), 13 deletions(-) diff --git a/check_process b/check_process index ac78f5c..38c0fba 100644 --- a/check_process +++ b/check_process @@ -8,7 +8,7 @@ password="1Strong-Password" ; Checks pkg_linter=1 - setup_sub_dir=1 + setup_sub_dir=0 setup_root=1 setup_nourl=0 setup_private=1 @@ -16,8 +16,8 @@ upgrade=1 #upgrade=1 from_commit=CommitHash backup_restore=1 - multi_instance=1 - change_url=1 + multi_instance=0 + change_url=0 ;;; Options Email= Notification=none diff --git a/scripts/backup b/scripts/backup index ae6faaf..1f20e98 100644 --- a/scripts/backup +++ b/scripts/backup @@ -8,6 +8,7 @@ # Keep this path for calling _common.sh inside the execution's context of backup and restore scripts source ../settings/scripts/_common.sh +source ../settings/scripts/ynh_add_swap source /usr/share/yunohost/helpers #================================================= @@ -69,14 +70,6 @@ ynh_backup --src_path="/etc/logrotate.d/$app" ynh_backup --src_path="/etc/systemd/system/$app-web.service" ynh_backup --src_path="/etc/systemd/system/$app-sidekiq.service" -#================================================= -# BACKUP VARIOUS FILES -#================================================= - -# ynh_backup --src_path="/etc/cron.d/$app" - -ynh_backup --src_path="/etc/$app/" - #================================================= # BACKUP THE MYSQL DATABASE #================================================= diff --git a/scripts/restore b/scripts/restore index b23652b..185baa9 100644 --- a/scripts/restore +++ b/scripts/restore @@ -8,6 +8,7 @@ # Keep this path for calling _common.sh inside the execution's context of backup and restore scripts source ../settings/scripts/_common.sh +source ../settings/scripts/ynh_add_swap source /usr/share/yunohost/helpers #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index d3d4cdb..a882c0b 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -204,8 +204,8 @@ chown $app:$app "$diaspora_toml" ynh_script_progression --message="Upgrading systemd configuration..." --weight=1 # Create a dedicated systemd config -ynh_add_systemd_config --service="$app-web" --template="glitchsoc-web.service" -ynh_add_systemd_config --service="$app-sidekiq" --template="glitchsoc-sidekiq.service" +ynh_add_systemd_config --service="$app-web" --template="acropolis-web.service" +ynh_add_systemd_config --service="$app-sidekiq" --template="acropolis-sidekiq.service" ynh_script_progression --message="Upgrading acropolis..."