From b192bcb703d7c2005f77e22f902b7488e1bce935 Mon Sep 17 00:00:00 2001 From: Thomas <51749973+Thovi98@users.noreply.github.com> Date: Thu, 15 Jun 2023 22:25:30 +0200 Subject: [PATCH] some cleanings --- scripts/change_url | 2 +- scripts/install | 9 +-------- scripts/restore | 2 +- scripts/upgrade | 22 +--------------------- tests.toml | 2 +- 5 files changed, 5 insertions(+), 32 deletions(-) diff --git a/scripts/change_url b/scripts/change_url index 2e45e03..63b5a55 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -50,7 +50,7 @@ chown $app:$app "$install_dir/live/config/options.yml" ynh_script_progression --message="Starting a systemd service..." # Start a systemd service -ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="http: starting web server at" +ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="Started AI-Powered Photos App for the Decentralized Web" #================================================= # END OF SCRIPT diff --git a/scripts/install b/scripts/install index f192416..8c49a55 100755 --- a/scripts/install +++ b/scripts/install @@ -57,13 +57,6 @@ ynh_setup_source --dest_dir="$install_dir/build" mkdir -p "$install_dir/live/" -ls -lah "$install_dir/" -ls -lah "$install_dir/build/" -ls -lah "$install_dir/build/opt/" -ls -lah "$install_dir/build/opt/photoprism/" -ls -lah "$install_dir/build/photoprism/" - - rsync -a "$install_dir/build/opt/photoprism/" "$install_dir/live/" ynh_secure_remove --file="$install_dir/build" @@ -125,7 +118,7 @@ yunohost service add $app --description="AI-Powered Photos App for the Decentral ynh_script_progression --message="Starting a systemd service..." # Start a systemd service -ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="http: starting web server at" +ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="Started AI-Powered Photos App for the Decentralized Web" #================================================= # END OF SCRIPT diff --git a/scripts/restore b/scripts/restore index 5af031e..c8e492f 100755 --- a/scripts/restore +++ b/scripts/restore @@ -84,7 +84,7 @@ yunohost service add $app --description="AI-Powered Photos App for the Decentral #================================================= ynh_script_progression --message="Starting a systemd service..." -ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="http: starting web server at" +ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="Started AI-Powered Photos App for the Decentralized Web" #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index 71e9cf3..0edc771 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -31,22 +31,6 @@ if [ -z "$language_key" ]; then ynh_app_setting_delete --app=$app --key=language fi -#================================================= -# DOWNLOAD, CHECK AND UNPACK SOURCE -#================================================= - -if [ "$upgrade_type" == "UPGRADE_APP" ] -then - ynh_script_progression --message="Upgrading source files..." - - -fi - -chmod 750 "$install_dir" -chmod -R o-rwx "$install_dir" -chown -R $app:www-data "$install_dir" - - #================================================= # NGINX CONFIGURATION #================================================= @@ -133,11 +117,7 @@ yunohost service add $app --description="AI-Powered Photos App for the Decentral #================================================= ynh_script_progression --message="Starting a systemd service..." -ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="http: starting web server at" - - - - +ynh_exec_warn_less ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" --line_match="Started AI-Powered Photos App for the Decentralized Web" #================================================= # END OF SCRIPT diff --git a/tests.toml b/tests.toml index 1cbd6ce..08e2532 100644 --- a/tests.toml +++ b/tests.toml @@ -2,4 +2,4 @@ test_format = 1.0 [default] -test_upgrade_from.fe71ba9.name = "Upgrade from packaging v1" +test_upgrade_from.fe71ba9.name = "Packaging v1"