From 09453e8d3ccf538629874df04eeecebe2223ab4f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Sat, 2 Sep 2023 17:58:24 +0200 Subject: [PATCH] Set auth_header = false for SSO, because Jellyfin expects custom data in the Authorization header. --- scripts/install | 6 +++++- scripts/upgrade | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/scripts/install b/scripts/install index 0b4d6d4..11a37ba 100644 --- a/scripts/install +++ b/scripts/install @@ -220,8 +220,12 @@ then ynh_permission_update --permission="main" --add="visitors" fi +# auth_header=false is because Jellyfin expects custom data in the Authorization HTTP header +# (notably, for Jellyfin Vue) +ynh_permission_url --permission="main" --auth_header=false + # Only the admin can access the admin panel of the app (if the app has an admin panel) -ynh_permission_create --permission="admin" --allowed=$admin +ynh_permission_create --permission="admin" --auth_header=false --allowed=$admin #================================================= # RELOAD NGINX diff --git a/scripts/upgrade b/scripts/upgrade index 1f16252..057f17e 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -86,9 +86,13 @@ fi if ! ynh_permission_exists --permission="admin"; then # Create the required permissions - ynh_permission_create --permission="admin" --allowed=$admin + ynh_permission_create --permission="admin" --auth_header=false --allowed=$admin fi +# Update SSO permissions with --auth_header=false (notably, for Jellyfin Vue) +ynh_permission_url --permission="main" --auth_header=false +ynh_permission_url --permission="admin" --auth_header=false + # If discovery key does not exist, create it if [ -z "$discovery" ]; then discovery=0