From 19edf1a7a18f464118063ac37c54080785ab9470 Mon Sep 17 00:00:00 2001 From: tituspijean Date: Wed, 1 Nov 2023 15:11:41 +0100 Subject: [PATCH] Add config panel to disable Radarr auth system --- config_panel.toml | 12 ++++++++++++ doc/POST_UPGRADE.d/5.0.3.8127~ynh2.md | 4 ++++ doc/POST_UPGRADE.d/5.0.3.8127~ynh2_fr.md | 3 +++ scripts/config | 12 ++++++++++++ 4 files changed, 31 insertions(+) create mode 100644 config_panel.toml create mode 100644 doc/POST_UPGRADE.d/5.0.3.8127~ynh2.md create mode 100644 doc/POST_UPGRADE.d/5.0.3.8127~ynh2_fr.md create mode 100644 scripts/config diff --git a/config_panel.toml b/config_panel.toml new file mode 100644 index 0000000..3d270b0 --- /dev/null +++ b/config_panel.toml @@ -0,0 +1,12 @@ +version = "1.0" + +[authentication] + +services = ["__APP__"] + + [authentication.authentication] + + [authentication.authentication.external_authentication] + ask.en = "Set Radarr's authentication method to External and rely on YunoHost's permission system." + ask.fr = "Paramétrer la méthode d'authentication de Radarr sur External et utiliser le système de permissions de YunoHost." + type = "button" diff --git a/doc/POST_UPGRADE.d/5.0.3.8127~ynh2.md b/doc/POST_UPGRADE.d/5.0.3.8127~ynh2.md new file mode 100644 index 0000000..0f5501d --- /dev/null +++ b/doc/POST_UPGRADE.d/5.0.3.8127~ynh2.md @@ -0,0 +1,4 @@ +As of recent versions, Radarr is forcing its users to use an authentication method. + +Since YunoHost offers its own permissions system you can make sure Radarr's own system is disabled by using the ["Authentication" + config panel](#/apps/__APP__/authentication) of the app in YunoHost's webadmin. diff --git a/doc/POST_UPGRADE.d/5.0.3.8127~ynh2_fr.md b/doc/POST_UPGRADE.d/5.0.3.8127~ynh2_fr.md new file mode 100644 index 0000000..1f2167b --- /dev/null +++ b/doc/POST_UPGRADE.d/5.0.3.8127~ynh2_fr.md @@ -0,0 +1,3 @@ +Depuis de récentes versions, Radarr force ses utilisateurs à utiliser une méthode d'authentification. + +Puisque YunoHost offre son propre système d'authentification vous pouvez désactiver le propre système de Radarr en utilisant [le panneau de configuration "Authentication"](#/apps/__APP__/authentication) de la webadmin de YunoHost. diff --git a/scripts/config b/scripts/config new file mode 100644 index 0000000..02a7d01 --- /dev/null +++ b/scripts/config @@ -0,0 +1,12 @@ +#!/bin/bash + +source /usr/share/yunohost/helpers +ynh_abort_if_errors + +data_dir=$(ynh_app_setting_get --app=$app --key=data_dir) + +run__external_authentication() { + ynh_replace_string --match_string="[[:alnum:]]*" --replace_string="External" --target_file="$data_dir/config.xml" +} + +ynh_app_config_run $1