feat: add interface user permission (#20424)

* feat: add interface user permission

Adds admin configurable user / group permissions for the interface settings section

* rename
This commit is contained in:
Classic298
2026-01-06 20:23:46 +04:00
committed by GitHub
parent 17490381f5
commit cc046695e6
5 changed files with 50 additions and 1 deletions
+8
View File
@@ -1471,6 +1471,11 @@ USER_PERMISSIONS_FEATURES_API_KEYS = (
)
USER_PERMISSIONS_SETTINGS_INTERFACE = (
os.environ.get("USER_PERMISSIONS_SETTINGS_INTERFACE", "True").lower() == "true"
)
DEFAULT_USER_PERMISSIONS = {
"workspace": {
"models": USER_PERMISSIONS_WORKSPACE_MODELS_ACCESS,
@@ -1529,6 +1534,9 @@ DEFAULT_USER_PERMISSIONS = {
"image_generation": USER_PERMISSIONS_FEATURES_IMAGE_GENERATION,
"code_interpreter": USER_PERMISSIONS_FEATURES_CODE_INTERPRETER,
},
"settings": {
"interface": USER_PERMISSIONS_SETTINGS_INTERFACE,
},
}
USER_PERMISSIONS = PersistentConfig(