diff --git a/scripts/backup b/scripts/backup index 5fcb288..1e33267 100755 --- a/scripts/backup +++ b/scripts/backup @@ -79,7 +79,7 @@ ynh_psql_dump_db --database="$db_name" > db.sql #================================================= # BACKUP THE DATA DIRECTORY #================================================= -ynh_script_progression --message="Backing up data directory..." +ynh_print_info --message="Backing up data directory..." ynh_backup --src_path="$datadir" --is_big diff --git a/scripts/install b/scripts/install index 4a35df8..5a4b37c 100755 --- a/scripts/install +++ b/scripts/install @@ -30,7 +30,7 @@ path_url="/" admin=$YNH_APP_ARG_ADMIN is_public=$YNH_APP_ARG_IS_PUBLIC password=$YNH_APP_ARG_PASSWORD -name=$YNH_APP_ARG_NAME +name="${YNH_APP_ARG_NAME// /_}" registration=$YNH_APP_ARG_REGISTRATION cache=$YNH_APP_ARG_CACHE size=$YNH_APP_ARG_SIZE @@ -253,7 +253,7 @@ chown -R "$app":"$app" "$final_path" #================================================= ynh_script_progression --message="Integrating service in YunoHost..." -yunohost service add $app --description "$app daemon for Pleroma" --log_type "systemd" +yunohost service add $app --description "$app daemon for Pleroma" #================================================= # SETUP SSOWAT diff --git a/scripts/restore b/scripts/restore index c4e556c..f8692d7 100755 --- a/scripts/restore +++ b/scripts/restore @@ -136,14 +136,14 @@ ynh_psql_execute_file_as_root --file="./db.sql" --database="$db_name" ynh_script_progression --message="Restoring the systemd configuration..." ynh_restore_file --origin_path="/etc/systemd/system/$app.service" -systemctl enable $app.service +systemctl enable $app.service --quiet #================================================= # INTEGRATE SERVICE IN YUNOHOST #================================================= ynh_script_progression --message="Integrating service in YunoHost..." -yunohost service add $app --description "$app daemon for Pleroma" --log_type "systemd" +yunohost service add $app --description "$app daemon for Pleroma" #================================================= # START SYSTEMD SERVICE diff --git a/scripts/upgrade b/scripts/upgrade index 3f49609..29f3ed9 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -285,16 +285,11 @@ ynh_script_progression --message="Securing files and directories..." chown -R "$app":"$app" "$final_path" #================================================= -# SETUP SSOWAT +# INTEGRATE SERVICE IN YUNOHOST #================================================= -ynh_script_progression --message="Upgrading SSOwat configuration..." +ynh_script_progression --message="Integrating service in YunoHost..." -# Make app public if necessary -if [ $is_public -eq 1 ] -then - # unprotected_uris allows SSO credentials to be passed anyway - ynh_app_setting_set --app=$app --key=unprotected_uris --value="/" -fi +yunohost service add $app --description "$app daemon for Pleroma" #================================================= # START SYSTEMD SERVICE @@ -306,6 +301,18 @@ if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then sleep 60 fi +#================================================= +# SETUP SSOWAT +#================================================= +ynh_script_progression --message="Upgrading SSOwat configuration..." + +# Make app public if necessary +if [ $is_public -eq 1 ] +then + # unprotected_uris allows SSO credentials to be passed anyway + ynh_app_setting_set --app=$app --key=unprotected_uris --value="/" +fi + #================================================= # RELOAD NGINX #=================================================