From 1cce1b27067be7ad8debdc79d3eddaca821ef750 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sat, 2 Jul 2022 08:42:47 +0200 Subject: [PATCH 1/4] Update install --- scripts/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/install b/scripts/install index 1e8c1d9..d9d1870 100644 --- a/scripts/install +++ b/scripts/install @@ -47,7 +47,7 @@ ynh_script_progression --message="Storing installation settings..." --weight=2 ynh_app_setting_set --app=$app --key=domain --value=$domain ynh_app_setting_set --app=$app --key=path --value=$path_url ynh_app_setting_set --app=$app --key=admin --value=$admin -ynh_app_setting_set --app=$app --key=password --value=$password +ynh_app_setting_set --app=$app --key=password --value="$password" #================================================= # STANDARD MODIFICATIONS From 62e8fe06f0c93b7a8f5cd787985b63d9cd2185e7 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sat, 2 Jul 2022 08:46:52 +0200 Subject: [PATCH 2/4] cleaning --- conf/miniflux.conf | 2 +- scripts/install | 4 +++- scripts/restore | 5 +++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/conf/miniflux.conf b/conf/miniflux.conf index aefe59c..31c3714 100644 --- a/conf/miniflux.conf +++ b/conf/miniflux.conf @@ -1,6 +1,6 @@ BASE_URL=https://__DOMAIN____PATH__ LISTEN_ADDR=127.0.0.1:__PORT__ -DATABASE_URL=postgres://__DB_NAME__:__DB_PWD__@localhost/__DB_NAME__?sslmode=disable +DATABASE_URL=postgres://__DB_USER__:__DB_PWD__@localhost/__DB_NAME__?sslmode=disable RUN_MIGRATIONS=1 CREATE_ADMIN=1 ADMIN_USERNAME=__ADMIN__ diff --git a/scripts/install b/scripts/install index d9d1870..676a45e 100644 --- a/scripts/install +++ b/scripts/install @@ -81,9 +81,10 @@ ynh_system_user_create --username=$app --home_dir=$final_path ynh_script_progression --message="Creating a PostgreSQL database..." --weight=2 db_name=$(ynh_sanitize_dbid --db_name=$app) +db_user=$db_name ynh_app_setting_set --app=$app --key=db_name --value=$db_name ynh_psql_test_if_first_run -ynh_psql_setup_db --db_user=$db_name --db_name=$db_name +ynh_psql_setup_db --db_user=$db_user --db_name=$db_name ynh_psql_execute_as_root --sql="CREATE EXTENSION hstore;" --database=$db_name @@ -115,6 +116,7 @@ ynh_add_nginx_config ynh_script_progression --message="Adding a configuration file..." --weight=1 ynh_add_config --template="../conf/miniflux.conf" --destination="$final_path/$app.conf" + chmod 600 "$final_path/$app.conf" chown $app "$final_path/$app.conf" diff --git a/scripts/restore b/scripts/restore index 79507c2..8c74d36 100644 --- a/scripts/restore +++ b/scripts/restore @@ -28,14 +28,14 @@ path_url=$(ynh_app_setting_get --app=$app --key=path) final_path=$(ynh_app_setting_get --app=$app --key=final_path) db_name=$(ynh_app_setting_get --app=$app --key=db_name) db_user=$db_name -db_pwd=$(ynh_app_setting_get --app=$app --key=psqlpwd) #================================================= # CHECK IF THE APP CAN BE RESTORED #================================================= ynh_script_progression --message="Validating restoration parameters..." --weight=2 -test ! -d $final_path || ynh_die --message="There is already a directory: $final_path " +test ! -d $final_path \ + || ynh_die --message="There is already a directory: $final_path " #================================================= # STANDARD RESTORATION STEPS @@ -79,6 +79,7 @@ ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies #================================================= ynh_script_progression --message="Restoring the PostgreSQL database..." --weight=6 +db_pwd=$(ynh_app_setting_get --app=$app --key=psqlpwd) ynh_psql_test_if_first_run ynh_psql_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd ynh_psql_execute_file_as_root --file="./db.sql" --database=$db_name From 551eb49bc77f69dba65fa09f6817dfa910a510a8 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sat, 2 Jul 2022 08:47:42 +0200 Subject: [PATCH 3/4] Update manifest.json --- manifest.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.json b/manifest.json index 967d895..8ac01a6 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "Minimalist and opinionated RSS feed reader", "fr": "Agrégateur de flux RSS minimaliste" }, - "version": "2.0.37~ynh1", + "version": "2.0.37~ynh2", "url": "https://miniflux.app/", "upstream": { "license": "Apache-2.0", From f57b7e76dfe94aeefdfdc32d2b580a927573e6f7 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Sat, 2 Jul 2022 06:47:47 +0000 Subject: [PATCH 4/4] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2c975e2..fe52038 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in Minimalist and opinionated RSS feed reader -**Shipped version:** 2.0.37~ynh1 +**Shipped version:** 2.0.37~ynh2 ## Screenshots diff --git a/README_fr.md b/README_fr.md index e297a65..7ab4829 100644 --- a/README_fr.md +++ b/README_fr.md @@ -17,7 +17,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour Minimalist and opinionated RSS feed reader -**Version incluse :** 2.0.37~ynh1 +**Version incluse :** 2.0.37~ynh2 ## Captures d'écran