1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/jellyfin_ynh.git synced 2024-09-03 19:26:29 +02:00

Merge pull request #137 from YunoHost-Apps/Tagadda-patch-1

Remove sudoers file
This commit is contained in:
Tagada 2023-09-26 16:29:29 +02:00 committed by GitHub
commit bd74c1f614
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 2 deletions

View file

@ -214,8 +214,12 @@ then
ynh_permission_update --permission="main" --add="visitors" ynh_permission_update --permission="main" --add="visitors"
fi 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) # 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 # RELOAD NGINX

View file

@ -94,6 +94,7 @@ ynh_script_progression --message="Removing various files..." --weight=1
ynh_secure_remove --file="$final_path" ynh_secure_remove --file="$final_path"
ynh_secure_remove --file="$config_path" ynh_secure_remove --file="$config_path"
ynh_secure_remove --file="/etc/systemd/system/jellyfin.service.d" ynh_secure_remove --file="/etc/systemd/system/jellyfin.service.d"
ynh_secure_remove --file="/etc/sudoers.d/jellyfin-sudoers"
# Remove the log files # Remove the log files
ynh_secure_remove --file="/var/log/$app" ynh_secure_remove --file="/var/log/$app"

View file

@ -86,9 +86,13 @@ fi
if ! ynh_permission_exists --permission="admin"; then if ! ynh_permission_exists --permission="admin"; then
# Create the required permissions # Create the required permissions
ynh_permission_create --permission="admin" --allowed=$admin ynh_permission_create --permission="admin" --auth_header=false --allowed=$admin
fi 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 discovery key does not exist, create it
if [ -z "$discovery" ]; then if [ -z "$discovery" ]; then
discovery=0 discovery=0