Skip to content

Commit 19b5542

Browse files
committed
Update LLMSTACK_HOST and LLMSTACK_PORT in settings.py
1 parent 45413e6 commit 19b5542

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

llmstack/server/settings.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,14 @@
1616
# SECURITY WARNING: don't run with debug turned on in production!
1717
DEBUG = os.getenv("DEBUG", "False") == "True"
1818

19+
LLMSTACK_PORT = os.getenv("LLMSTACK_PORT", 3000)
20+
LLMSTACK_HOST = os.getenv("LLMSTACK_HOST", "localhost")
21+
1922
ALLOWED_HOSTS = os.getenv(
2023
"ALLOWED_HOSTS",
21-
"127.0.0.1,localhost",
24+
f"127.0.0.1,localhost,{LLMSTACK_HOST}",
2225
).split(",")
2326

24-
LLMSTACK_PORT = os.getenv("LLMSTACK_PORT", 3000)
2527

2628
RUNNER_HOST = os.getenv("RUNNER_HOST")
2729
RUNNER_PORT = os.getenv("RUNNER_PORT")
@@ -30,7 +32,7 @@
3032

3133
CSRF_TRUSTED_ORIGINS = os.getenv(
3234
"CSRF_TRUSTED_ORIGINS",
33-
f"http://127.0.0.1:{LLMSTACK_PORT},http://localhost:{LLMSTACK_PORT}",
35+
f"http://{LLMSTACK_HOST}:{LLMSTACK_PORT}",
3436
).split(",")
3537

3638
STATIC_ROOT = os.path.join(BASE_DIR, "static")

0 commit comments

Comments
 (0)