forked from open-webui/open-webui
recompose the name of environment variables
This commit is contained in:
parent
b0245a7eff
commit
849a0b973d
2 changed files with 6 additions and 6 deletions
|
@ -32,13 +32,13 @@ import logging
|
||||||
from config import (
|
from config import (
|
||||||
SRC_LOG_LEVELS,
|
SRC_LOG_LEVELS,
|
||||||
CACHE_DIR,
|
CACHE_DIR,
|
||||||
IMAGES_GENERATION_ENGINE,
|
IMAGE_GENERATION_ENGINE,
|
||||||
ENABLE_IMAGE_GENERATION,
|
ENABLE_IMAGE_GENERATION,
|
||||||
AUTOMATIC1111_BASE_URL,
|
AUTOMATIC1111_BASE_URL,
|
||||||
COMFYUI_BASE_URL,
|
COMFYUI_BASE_URL,
|
||||||
IMAGES_OPENAI_API_BASE_URL,
|
IMAGES_OPENAI_API_BASE_URL,
|
||||||
IMAGES_OPENAI_API_KEY,
|
IMAGES_OPENAI_API_KEY,
|
||||||
IMAGES_MODEL,
|
IMAGE_GENERATION_MODEL,
|
||||||
IMAGE_SIZE,
|
IMAGE_SIZE,
|
||||||
IMAGE_STEPS,
|
IMAGE_STEPS,
|
||||||
)
|
)
|
||||||
|
@ -59,13 +59,13 @@ app.add_middleware(
|
||||||
allow_headers=["*"],
|
allow_headers=["*"],
|
||||||
)
|
)
|
||||||
|
|
||||||
app.state.ENGINE = IMAGES_GENERATION_ENGINE
|
app.state.ENGINE = IMAGE_GENERATION_ENGINE
|
||||||
app.state.ENABLED = ENABLE_IMAGE_GENERATION
|
app.state.ENABLED = ENABLE_IMAGE_GENERATION
|
||||||
|
|
||||||
app.state.OPENAI_API_BASE_URL = IMAGES_OPENAI_API_BASE_URL
|
app.state.OPENAI_API_BASE_URL = IMAGES_OPENAI_API_BASE_URL
|
||||||
app.state.OPENAI_API_KEY = IMAGES_OPENAI_API_KEY
|
app.state.OPENAI_API_KEY = IMAGES_OPENAI_API_KEY
|
||||||
|
|
||||||
app.state.MODEL = IMAGES_MODEL
|
app.state.MODEL = IMAGE_GENERATION_MODEL
|
||||||
|
|
||||||
|
|
||||||
app.state.AUTOMATIC1111_BASE_URL = AUTOMATIC1111_BASE_URL
|
app.state.AUTOMATIC1111_BASE_URL = AUTOMATIC1111_BASE_URL
|
||||||
|
|
|
@ -531,7 +531,7 @@ WHISPER_MODEL_AUTO_UPDATE = (
|
||||||
# Images
|
# Images
|
||||||
####################################
|
####################################
|
||||||
|
|
||||||
IMAGES_GENERATION_ENGINE = os.getenv("IMAGES_GENERATION_ENGINE", "")
|
IMAGE_GENERATION_ENGINE = os.getenv("IMAGE_GENERATION_ENGINE", "")
|
||||||
|
|
||||||
ENABLE_IMAGE_GENERATION = (
|
ENABLE_IMAGE_GENERATION = (
|
||||||
os.environ.get("ENABLE_IMAGE_GENERATION", "").lower() == "true"
|
os.environ.get("ENABLE_IMAGE_GENERATION", "").lower() == "true"
|
||||||
|
@ -549,7 +549,7 @@ IMAGE_SIZE = os.getenv("IMAGE_SIZE", "512x512")
|
||||||
|
|
||||||
IMAGE_STEPS = int(os.getenv("IMAGE_STEPS", 50))
|
IMAGE_STEPS = int(os.getenv("IMAGE_STEPS", 50))
|
||||||
|
|
||||||
IMAGES_MODEL = os.getenv("IMAGES_MODEL", "")
|
IMAGE_GENERATION_MODEL = os.getenv("IMAGE_GENERATION_MODEL", "")
|
||||||
|
|
||||||
####################################
|
####################################
|
||||||
# Audio
|
# Audio
|
||||||
|
|
Loading…
Reference in a new issue