diff --git a/README.md b/README.md index cf6ea9c..27fafd7 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ You can configure Invidious by modifying the configuration file `/var/www/invidi ## Documentation * Official documentation: https://github.com/iv-org/documentation - * YunoHost documentation: https://yunohost.org/#/app_invidious + * YunoHost documentation: https://yunohost.org/en/app_invidious ## YunoHost specific features diff --git a/README_fr.md b/README_fr.md index 8d9129f..cf20224 100644 --- a/README_fr.md +++ b/README_fr.md @@ -28,7 +28,7 @@ Vous pouvez configurer Invidious en modifiant le fichier de configuration `/var/ ## Documentation * Documentation officielle : https://github.com/iv-org/documentation - * Documentation YunoHost : https://yunohost.org/#/app_invidious_fr + * Documentation YunoHost : https://yunohost.org/fr/app_invidious ## Caractéristiques spécifiques YunoHost diff --git a/check_process b/check_process index cf586a4..47d4fda 100644 --- a/check_process +++ b/check_process @@ -14,7 +14,6 @@ upgrade=1 backup_restore=1 multi_instance=0 - port_already_use=0 change_url=0 ;;; Options Email= diff --git a/conf/app.src b/conf/app.src new file mode 100644 index 0000000..e69de29 diff --git a/manifest.json b/manifest.json index 7856ce7..dfb7c2c 100644 --- a/manifest.json +++ b/manifest.json @@ -6,14 +6,14 @@ "en": "Alternative front-end to YouTube", "fr": "Front-end alternatif à YouTube" }, - "version": "0.20.1~ynh6", + "version": "0.20.1~ynh8", "url": "https://invidio.us/", "license": "GPL-3.0-only", "maintainer": { "name": "eric_G" }, "requirements": { - "yunohost": ">= 4.0.0" + "yunohost": ">= 4.1.7" }, "multi_instance": false, "services": [ @@ -24,19 +24,11 @@ { "name": "domain", "type": "domain", - "ask": { - "en": "Choose a domain name for Invidious", - "fr": "Choisissez un nom de domaine pour Invidious" - }, "example": "domain.org" }, { "name": "is_public", "type": "boolean", - "ask": { - "en": "Is it a public site?", - "fr": "Est-ce un site public ?" - }, "help": { "en": "If enabled, Invidious will be accessible by people who do not have an account. This can be changed later via the webadmin.", "fr": "Si cette case est cochée, Invidious sera accessible aux personnes n’ayant pas de compte. Vous pourrez changer ceci plus tard via la webadmin." diff --git a/scripts/_common.sh b/scripts/_common.sh index 8f6e28d..4aeb6e7 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= # dependencies used by the app -pkg_dependencies="crystal apt-transport-https libssl-dev libxml2-dev libyaml-dev libgmp-dev libreadline-dev postgresql librsvg2-bin libsqlite3-dev zlib1g-dev" +pkg_dependencies="apt-transport-https libssl-dev libxml2-dev libyaml-dev libgmp-dev libreadline-dev postgresql librsvg2-bin libsqlite3-dev zlib1g-dev" #crystal #================================================= # PERSONAL HELPERS diff --git a/scripts/install b/scripts/install index e1ea2bc..c3ee073 100644 --- a/scripts/install +++ b/scripts/install @@ -66,8 +66,10 @@ ynh_app_setting_set --app=$app --key=port --value=$port #================================================= ynh_script_progression --message="Installing dependencies..." --weight=9 -ynh_exec_warn_less apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 379CE192D401AB61 -ynh_install_extra_repo --repo="deb https://dl.bintray.com/crystal/deb all stable" --append +#ynh_exec_warn_less apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 379CE192D401AB61 +#ynh_install_extra_repo --repo="deb https://dl.bintray.com/crystal/deb all stable" --append + +ynh_exec_warn_less curl -fsSL https://crystal-lang.org/install.sh | bash -s -- --crystal=0.36 ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies @@ -131,7 +133,6 @@ popd || ynh_die ynh_script_progression --message="Modifying a config file..." ynh_add_config --template="../conf/config.yml" --destination="$final_path/config/config.yml" -ynh_store_file_checksum --file="$final_path/config/config.yml" #================================================= # SETUP SYSTEMD diff --git a/scripts/upgrade b/scripts/upgrade index 5d01812..1e734d1 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -32,6 +32,18 @@ ynh_script_progression --message="Checking version..." upgrade_type=$(ynh_check_app_version_changed) +#================================================= +# ENSURE DOWNWARD COMPATIBILITY +#================================================= +ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 + +# Cleaning legacy permissions +if ynh_legacy_permissions_exists; then + ynh_legacy_permissions_delete_all + + ynh_app_setting_delete --app=$app --key=is_public +fi + #================================================= # BACKUP BEFORE UPGRADE THEN ACTIVE TRAP #================================================= @@ -60,8 +72,10 @@ ynh_systemd_action --service_name=$app --action=stop --log_path=systemd #================================================= ynh_script_progression --message="Upgrading dependencies..." --weight=8 -ynh_exec_warn_less apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 379CE192D401AB61 -ynh_install_extra_repo --repo="deb https://dl.bintray.com/crystal/deb all stable" --append +#ynh_exec_warn_less apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 379CE192D401AB61 +#ynh_install_extra_repo --repo="deb https://dl.bintray.com/crystal/deb all stable" --append + +ynh_exec_warn_less curl -fsSL https://crystal-lang.org/install.sh | bash -s -- --crystal=0.36 ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies @@ -103,12 +117,8 @@ ynh_system_user_create --username=$app #================================================= ynh_script_progression --message="Modifying a config file..." --weight=3 -ynh_backup_if_checksum_is_different --file="$final_path/config/config.yml" - ynh_add_config --template="../conf/config.yml" --destination="$final_path/config/config.yml" -ynh_store_file_checksum --file="$final_path/config/config.yml" - #================================================= # SETUP SYSTEMD #=================================================