mirror of
https://github.com/YunoHost-Apps/invidious_ynh.git
synced 2024-09-03 19:15:55 +02:00
parent
7b5535dad2
commit
80fbb568a7
9 changed files with 65 additions and 11 deletions
|
@ -23,7 +23,7 @@ In addition to constituting an advantage in terms of confidentiality (the data d
|
|||
- Ability to subscribe to channels without creating a Google account
|
||||
|
||||
|
||||
**Shipped version:** 22.01.12~ynh1
|
||||
**Shipped version:** 22.01.14~ynh1
|
||||
|
||||
**Demo:** https://invidious.site/
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ En plus de constituer un avantage sur le plan de la confidentialité (les donné
|
|||
- Possibilité d'afficher les commentaires Reddit plutôt que les commentaires YouTube,
|
||||
- Possibilité de s'abonner aux chaines sans créer de compte Google
|
||||
|
||||
**Version incluse :** 22.01.12~ynh1
|
||||
**Version incluse :** 22.01.14~ynh1
|
||||
|
||||
**Démo :** https://invidious.site/
|
||||
|
||||
|
|
|
@ -252,7 +252,7 @@ hsts: true
|
|||
## Accepted values: true, false
|
||||
## Default: true
|
||||
##
|
||||
#registration_enabled: true
|
||||
registration_enabled: __REGISTRATION_ENABLED__
|
||||
|
||||
##
|
||||
## Allow/Forbid users to log-in. This setting affects the ability
|
||||
|
@ -261,7 +261,7 @@ hsts: true
|
|||
## Accepted values: true, false
|
||||
## Default: true
|
||||
##
|
||||
#login_enabled: true
|
||||
login_enabled: __LOGIN_ENABLED__
|
||||
|
||||
##
|
||||
## Enable/Disable the captcha challenge on the login page.
|
||||
|
@ -272,7 +272,7 @@ hsts: true
|
|||
## Accepted values: true, false
|
||||
## Default: true
|
||||
##
|
||||
#captcha_enabled: true
|
||||
captcha_enabled: __CAPTCHA_ENABLED__
|
||||
|
||||
##
|
||||
## List of usernames that will be granted administrator rights.
|
||||
|
|
|
@ -17,10 +17,6 @@ location __PATH__/ {
|
|||
}
|
||||
|
||||
location __PATH__/embed/ {
|
||||
# Force usage of https
|
||||
if ($scheme = http) {
|
||||
rewrite ^ https://$server_name$request_uri? permanent;
|
||||
}
|
||||
|
||||
proxy_pass http://127.0.0.1:__PORT__/embed/;
|
||||
proxy_redirect off;
|
||||
|
|
32
config_panel.toml
Normal file
32
config_panel.toml
Normal file
|
@ -0,0 +1,32 @@
|
|||
version = "1.0"
|
||||
|
||||
[main]
|
||||
name = "Invidious configuration"
|
||||
services = ["__APP__"]
|
||||
|
||||
[main.config]
|
||||
name = "Configuration Options"
|
||||
|
||||
[main.config.registration_enabled]
|
||||
ask = "Enable registration"
|
||||
type = "boolean"
|
||||
yes = "true"
|
||||
no = "false"
|
||||
help = "Allow/Forbid Invidious (local) account creation"
|
||||
bind = "registration_enabled:__FINALPATH__/config/config.yml"
|
||||
|
||||
[main.config.login_enabled]
|
||||
ask = "Enable login"
|
||||
type = "boolean"
|
||||
yes = "true"
|
||||
no = "false"
|
||||
help = "Allow/Forbid users to log-in"
|
||||
bind = "login_enabled:__FINALPATH__/config/config.yml"
|
||||
|
||||
[main.config.captcha_enabled]
|
||||
ask = "Enable captcha"
|
||||
type = "boolean"
|
||||
yes = "true"
|
||||
no = "false"
|
||||
help = "Enable/Disable the captcha challenge on the login page"
|
||||
bind = "captcha_enabled:__FINALPATH__/config/config.yml"
|
|
@ -6,7 +6,7 @@
|
|||
"en": "Alternative front-end to YouTube",
|
||||
"fr": "Front-end alternatif à YouTube"
|
||||
},
|
||||
"version": "22.01.12~ynh1",
|
||||
"version": "22.01.14~ynh1",
|
||||
"url": "https://invidio.us/",
|
||||
"upstream": {
|
||||
"license": "GPL-3.0-only",
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
# COMMON VARIABLES
|
||||
#=================================================
|
||||
|
||||
version_commit=b65dced646acf56f914a8916fd411237a141ecce
|
||||
version_commit=042ff8da643e9304f4d2c7db8f0c3cdba82d35ee
|
||||
|
||||
# dependencies used by the app
|
||||
pkg_dependencies="apt-transport-https libssl-dev libxml2-dev libyaml-dev libgmp-dev libreadline-dev postgresql librsvg2-bin imagemagick libsqlite3-dev zlib1g-dev libevent-dev pkg-config libpcre3-dev"
|
||||
|
|
|
@ -30,6 +30,10 @@ language=$YNH_APP_ARG_LANGUAGE
|
|||
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
registration_enabled="true"
|
||||
login_enabled="true"
|
||||
captcha_enabled="true"
|
||||
|
||||
#=================================================
|
||||
# CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS
|
||||
#=================================================
|
||||
|
@ -49,6 +53,9 @@ 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=language --value=$language
|
||||
ynh_app_setting_set --app=$app --key=registration_enabled --value=$registration_enabled
|
||||
ynh_app_setting_set --app=$app --key=login_enabled --value=$login_enabled
|
||||
ynh_app_setting_set --app=$app --key=captcha_enabled --value=$captcha_enabled
|
||||
|
||||
#=================================================
|
||||
# STANDARD MODIFICATIONS
|
||||
|
|
|
@ -25,6 +25,10 @@ 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)
|
||||
|
||||
registration_enabled=$(ynh_app_setting_get --app=$app --key=registration_enabled)
|
||||
login_enabled=$(ynh_app_setting_get --app=$app --key=login_enabled)
|
||||
captcha_enabled=$(ynh_app_setting_get --app=$app --key=captcha_enabled)
|
||||
|
||||
#=================================================
|
||||
# CHECK VERSION
|
||||
#=================================================
|
||||
|
@ -59,6 +63,21 @@ ynh_systemd_action --service_name=$app --action=stop --log_path=systemd
|
|||
#=================================================
|
||||
ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
|
||||
|
||||
if [ -z "$registration_enabled" ]; then
|
||||
registration_enabled="true"
|
||||
ynh_app_setting_set --app=$app --key=registration_enabled --value=$registration_enabled
|
||||
fi
|
||||
|
||||
if [ -z "$login_enabled" ]; then
|
||||
login_enabled="true"
|
||||
ynh_app_setting_set --app=$app --key=login_enabled --value=$login_enabled
|
||||
fi
|
||||
|
||||
if [ -z "$captcha_enabled" ]; then
|
||||
captcha_enabled="true"
|
||||
ynh_app_setting_set --app=$app --key=captcha_enabled --value=$captcha_enabled
|
||||
fi
|
||||
|
||||
# Cleaning legacy permissions
|
||||
if ynh_legacy_permissions_exists; then
|
||||
ynh_legacy_permissions_delete_all
|
||||
|
|
Loading…
Reference in a new issue