fix: add env variable for changing frontend app url
This commit is contained in:
parent
03858bc06b
commit
9715c0106e
2 changed files with 9 additions and 2 deletions
|
|
@ -176,7 +176,14 @@ ENABLE_BACKEND_ACCESS_CONTROL=False
|
||||||
|
|
||||||
# Cognee Cloud API settings for syncing data to/from cloud infrastructure
|
# Cognee Cloud API settings for syncing data to/from cloud infrastructure
|
||||||
COGNEE_CLOUD_API_URL="http://localhost:8001"
|
COGNEE_CLOUD_API_URL="http://localhost:8001"
|
||||||
COGNEE_CLOUD_AUTH_TOKEN="your-auth-token"
|
COGNEE_CLOUD_AUTH_TOKEN="your-api-key"
|
||||||
|
|
||||||
|
################################################################################
|
||||||
|
# UI Settings
|
||||||
|
################################################################################
|
||||||
|
|
||||||
|
# URL where the frontend is served, defaults to http://localhost:3000
|
||||||
|
UI_APP_URL=http://localhost:3000
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
# 🛠️ DEV Settings
|
# 🛠️ DEV Settings
|
||||||
|
|
|
||||||
|
|
@ -81,7 +81,7 @@ if CORS_ALLOWED_ORIGINS:
|
||||||
]
|
]
|
||||||
else:
|
else:
|
||||||
allowed_origins = [
|
allowed_origins = [
|
||||||
"http://localhost:3000",
|
os.getenv("UI_APP_URL", "http://localhost:3000"),
|
||||||
] # Block all except explicitly set origins
|
] # Block all except explicitly set origins
|
||||||
|
|
||||||
app.add_middleware(
|
app.add_middleware(
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue