diff --git a/README.md b/README.md index 1ab2e4c..126561a 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ If you don't have YunoHost, please see [here](https://yunohost.org/#/install) to Meilisearch is an opensource next generation search API. -**Shipped version:** 0.18.1 +**Shipped version:** 0.20.0 ## Screenshots @@ -32,8 +32,8 @@ It's an API and there is no authentification, without API key. #### Supported architectures -* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/meilisearch%20%28Apps%29.svg)](https://ci-apps.yunohost.org/ci/apps/meilisearch/) -* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/meilisearch%20%28Apps%29.svg)](https://ci-apps-arm.yunohost.org/ci/apps/meilisearch/) +* x86-64 - [![Build Status](https://ci-apps.yunohost.org/ci/logs/meilisearch.svg)](https://ci-apps.yunohost.org/ci/apps/meilisearch/) +* ARMv8-A - [![Build Status](https://ci-apps-arm.yunohost.org/ci/logs/meilisearch.svg)](https://ci-apps-arm.yunohost.org/ci/apps/meilisearch/) ## Links diff --git a/manifest.json b/manifest.json index 4c9b913..ae99103 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "Lightning Fast, Ultra Relevant, and Typo-Tolerant Search Engine.", "fr": "Moteur de recherche rapide, ultra-performant et tolérant aux fautes de frappe." }, - "version": "0.18.1~ynh1", + "version": "0.20.0~ynh1", "url": "https://www.meilisearch.com/", "license": "GPL-3.0", "maintainer": { @@ -15,7 +15,7 @@ "url": "https://julien.gomes-dias.dev" }, "requirements": { - "yunohost": ">= 3.8.1" + "yunohost": ">= 4.1.7" }, "multi_instance": true, "services": [ @@ -26,19 +26,11 @@ { "name": "domain", "type": "domain", - "ask": { - "en": "Choose a dedicated domain name for Meilisearch", - "fr": "Choisissez un nom de domaine dédié pour Meilisearch" - }, "example": "example.com" }, { "name": "is_public", "type": "boolean", - "ask": { - "en": "Is it a public application?", - "fr": "Est-ce une application publique ?" - }, "default": true }, { diff --git a/scripts/_common.sh b/scripts/_common.sh index fafea48..df49d65 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -1,6 +1,6 @@ #!/bin/bash -latest="v0.18.1" +latest="v0.20.0" ynh_detect_arch() { local architecture diff --git a/scripts/install b/scripts/install index 15223a5..117fec9 100644 --- a/scripts/install +++ b/scripts/install @@ -55,7 +55,6 @@ ynh_script_progression --message="Storing installation settings..." --weight=1 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=master_key --value=$master_key -ynh_app_setting_set --app=$app --key=is_public --value=$is_public ynh_app_setting_set --app=$app --key=final_path --value=$final_path ynh_app_setting_set --app=$app --key=allow_analyse --value=$allow_analyse @@ -92,8 +91,6 @@ mv "$release_file" /usr/bin/meilisearch #================================================= ynh_script_progression --message="Configuring NGINX web server..." --weight=8 -### `ynh_add_nginx_config` will use the file conf/nginx.conf - # Create a dedicated nginx config ynh_add_nginx_config @@ -170,7 +167,7 @@ if [ $is_public -eq 1 ] then # Everyone can access the app. # The "main" permission is automatically created before the install script. - ynh_permission_update --permission "main" --add "visitors" + ynh_permission_update --permission="main" --add="visitors" fi #================================================= diff --git a/scripts/restore b/scripts/restore index 21bc30d..41ba9cd 100644 --- a/scripts/restore +++ b/scripts/restore @@ -32,7 +32,6 @@ domain=$(ynh_app_setting_get --app=$app --key=domain) path_url=$(ynh_app_setting_get --app=$app --key=path) final_path=$(ynh_app_setting_get --app=$app --key=final_path) - #================================================= # CHECK IF THE APP CAN BE RESTORED #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index ccdfcec..10b3e94 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -19,7 +19,6 @@ app=$YNH_APP_INSTANCE_NAME domain=$(ynh_app_setting_get --app=$app --key=domain) path_url=$(ynh_app_setting_get --app=$app --key=path) -is_public=$(ynh_app_setting_get --app=$app --key=is_public) final_path=$(ynh_app_setting_get --app=$app --key=final_path) master_key=$(ynh_app_setting_get --app=$app --key=master_key) allow_analyse=$(ynh_app_setting_get --app=$app --key=allow_analyse) @@ -33,17 +32,8 @@ upgrade_type=$(ynh_check_app_version_changed) #================================================= # ENSURE DOWNWARD COMPATIBILITY #================================================= - ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 -# Fix is_public as a boolean value -if [ "$is_public" = "Yes" ]; then - ynh_app_setting_set --app=$app --key=is_public --value=1 - is_public=1 -elif [ "$is_public" = "No" ]; then - ynh_app_setting_set --app=$app --key=is_public --value=0 - is_public=0 -fi # If final_path doesn't exist, create it if [ -z "$final_path" ]; then @@ -51,6 +41,13 @@ if [ -z "$final_path" ]; then ynh_app_setting_set --app=$app --key=final_path --value=$final_path fi +# Cleaning legacy permissions +if ynh_legacy_permissions_exists; then + ynh_legacy_permissions_delete_all + + ynh_app_setting_delete --app=$app --key=is_public +fi + #================================================= # FIND AND OPEN A PORT #=================================================