forked from open-webui/open-webui
feat: image env var
This commit is contained in:
parent
2d7d6cfffc
commit
e3d253b040
2 changed files with 8 additions and 4 deletions
|
@ -35,8 +35,8 @@ from config import (
|
|||
ENABLE_IMAGE_GENERATION,
|
||||
AUTOMATIC1111_BASE_URL,
|
||||
COMFYUI_BASE_URL,
|
||||
OPENAI_API_BASE_URL,
|
||||
OPENAI_API_KEY,
|
||||
IMAGE_OPENAI_API_BASE_URL,
|
||||
IMAGE_OPENAI_API_KEY,
|
||||
)
|
||||
|
||||
|
||||
|
@ -58,8 +58,8 @@ app.add_middleware(
|
|||
app.state.ENGINE = ""
|
||||
app.state.ENABLED = ENABLE_IMAGE_GENERATION
|
||||
|
||||
app.state.OPENAI_API_BASE_URL = OPENAI_API_BASE_URL
|
||||
app.state.OPENAI_API_KEY = OPENAI_API_KEY
|
||||
app.state.OPENAI_API_BASE_URL = IMAGE_OPENAI_API_BASE_URL
|
||||
app.state.OPENAI_API_KEY = IMAGE_OPENAI_API_KEY
|
||||
|
||||
app.state.MODEL = ""
|
||||
|
||||
|
|
|
@ -487,6 +487,10 @@ AUTOMATIC1111_BASE_URL = os.getenv("AUTOMATIC1111_BASE_URL", "")
|
|||
COMFYUI_BASE_URL = os.getenv("COMFYUI_BASE_URL", "")
|
||||
|
||||
|
||||
IMAGE_OPENAI_API_BASE_URL = os.getenv("IMAGE_OPENAI_API_BASE_URL", OPENAI_API_BASE_URL)
|
||||
IMAGE_OPENAI_API_KEY = os.getenv("IMAGE_OPENAI_API_KEY", OPENAI_API_KEY)
|
||||
|
||||
|
||||
####################################
|
||||
# Audio
|
||||
####################################
|
||||
|
|
Loading…
Reference in a new issue