diff --git a/manifest.json b/manifest.json index 3d14d36..5c3a696 100644 --- a/manifest.json +++ b/manifest.json @@ -3,7 +3,7 @@ "id": "scrumblr", "packaging_format": 1, "description": { - "en": "Software for notes", + "en": "Software for post-it notes", "fr": "Application pour créer des post-it" }, "version": "0.2.0~ynh1", diff --git a/scripts/install b/scripts/install index 1221a29..e201c93 100644 --- a/scripts/install +++ b/scripts/install @@ -120,7 +120,7 @@ ynh_add_systemd_config pushd $final_path ynh_use_nodejs - $ynh_npm install >> 2>&1 + ynh_exec_warn_less $ynh_npm install popd #================================================= @@ -136,7 +136,7 @@ yunohost service add $app --description="Software for notes" --log="/var/log/$ap ynh_script_progression --message="Starting a systemd service..." --weight=2 # Start a systemd service -ynh_systemd_action --service_name=$app --action="start" --log_path=systemd +ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Server running at port" #================================================= # Set Public or private diff --git a/scripts/restore b/scripts/restore index 80c8abf..6435899 100644 --- a/scripts/restore +++ b/scripts/restore @@ -103,7 +103,7 @@ yunohost service add $app --description="Software for notes" --log="/var/log/$ap #================================================= ynh_script_progression --message="Starting a systemd service..." --weight=1 -ynh_systemd_action --service_name=$app --action="start" --log_path=systemd +ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Server running at port" #================================================= # GENERIC FINALIZATION diff --git a/scripts/upgrade b/scripts/upgrade index a2eb7a4..83208d9 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -83,8 +83,14 @@ if [ "$upgrade_type" == "UPGRADE_APP" ] then ynh_script_progression --message="Upgrading source files..." --weight=1 + ynh_secure_remove --file="$final_path" # Download, check integrity, uncompress and patch the source from app.src ynh_setup_source --dest_dir="$final_path" + + pushd $final_path + ynh_use_nodejs + ynh_exec_warn_less $ynh_npm install + popd fi chmod 750 "$final_path" @@ -111,7 +117,7 @@ ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version #================================================= ynh_script_progression --message="Upgrading systemd configuration..." --weight=1 -# Create a dedicated systemd config +ynh_replace_string --match_string="__ENV_PATH__" --replace_string="$PATH" --target_file="../conf/systemd.service" ynh_add_systemd_config #================================================= @@ -136,7 +142,7 @@ yunohost service add $app --description="Software for notes" --log="/var/log/$ap #================================================= ynh_script_progression --message="Starting a systemd service..." --weight=1 -ynh_systemd_action --service_name=$app --action="start" --log_path=systemd +ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Server running at port" #================================================= # RELOAD NGINX