feat: add WEBUI_AUTH_TRUSTED_EMAIL_HEADER for authenticating users by a trusted header

This is very yolo code, use at your own risk
This commit is contained in:
Jun Siang Cheah
2024-03-26 21:30:53 +00:00
committed by Jun Siang Cheah
parent 7d45d2762f
commit 29f13f34d3
8 changed files with 58 additions and 13 deletions

View File

@@ -171,6 +171,7 @@ async def get_app_config():
"images": images_app.state.ENABLED,
"default_models": webui_app.state.DEFAULT_MODELS,
"default_prompt_suggestions": webui_app.state.DEFAULT_PROMPT_SUGGESTIONS,
"trusted_header_auth": bool(webui_app.state.AUTH_TRUSTED_EMAIL_HEADER),
}