From ac6b540fd8779f76be12cbf05a3456357e7473a2 Mon Sep 17 00:00:00 2001 From: hjlarry Date: Tue, 13 Jan 2026 17:50:16 +0800 Subject: [PATCH] CORS config --- api/extensions/ext_socketio.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/api/extensions/ext_socketio.py b/api/extensions/ext_socketio.py index d898f795b1..470e0b08e2 100644 --- a/api/extensions/ext_socketio.py +++ b/api/extensions/ext_socketio.py @@ -1,3 +1,5 @@ import socketio -sio = socketio.Server(async_mode="gevent", cors_allowed_origins="*") +from configs import dify_config + +sio = socketio.Server(async_mode="gevent", cors_allowed_origins=dify_config.CONSOLE_CORS_ALLOW_ORIGINS)