Closed selfhoster1312 closed 1 year ago
I found cause: new default settings for LDAP plugin.
Possible to change in plugin settings: baseURL/web/index.html#!/configurationpage?name=LDAP-Auth
Will try to write script to give permission retroactively. EDIT: Here's a script. Don't forget to set API_KEY and JELLYFIN_URL at the top. Jellyfin URL should end with /
.
#! /usr/bin/env python3
API_KEY=""
JELLYFIN_URL=""
import json
import requests
def apiEndpoint(endpoint):
return JELLYFIN_URL + endpoint + "?api_key=" + API_KEY
def apiPost(endpoint, struct):
r = requests.post(apiEndpoint(endpoint), json=struct)
r.raise_for_status()
stripped = r.text.strip()
if stripped != "":
return r.json()
else:
return None
def apiGet(endpoint):
r = requests.get(apiEndpoint(endpoint))
r.raise_for_status()
stripped = r.text.strip()
if stripped != "":
return r.json()
else:
return None
users = apiGet('users')
for user in users:
if not user["Policy"]["EnableAllFolders"]:
print(user["Name"] + " doesn't have library access... enabling")
newPolicy = user["Policy"]
newPolicy["EnableAllFolders"] = True
apiPost('users/' + user["Id"] + '/Policy', newPolicy)
Describe the bug
When a new user is created on Yunohost, they do not have access to the media libraries configured in Jellyfin. I have to go and manually "enable access to all libraries".
Context
Jellyfin v10.8.5~ynh1
Steps to reproduce
Expected behavior
Previously, the user creation script granted access to all libraries by default. I don't know if it's regression in Yunohost package or upstream, but this changed a few months ago.
I think by default creating a user should grant them access to all libraries. If someone disagrees, it could be a setting on the Yunohost application config, or maybe a dedicated LDAP permission.