mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-20 06:31:02 +08:00
Fix secret key inconsistency cross the RAGFlow servers (#14591)
### What problem does this PR solve? A and B, two API servers and a REDIS server. If A and REDIS restart, B will hold the obsolete secret key and will lead to error. TODO: app.config['SECRET_KEY'] and app.secret_key still hold obsolete secret key. ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) --------- Signed-off-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
@@ -49,6 +49,7 @@ def _load_apps_module(monkeypatch):
|
||||
|
||||
settings_mod = ModuleType("common.settings")
|
||||
settings_mod.SECRET_KEY = "test-secret-key"
|
||||
settings_mod.get_secret_key = lambda: "test-secret-key"
|
||||
settings_mod.init_settings = lambda: None
|
||||
settings_mod.decrypt_database_config = lambda name=None: {}
|
||||
monkeypatch.setitem(sys.modules, "common.settings", settings_mod)
|
||||
|
||||
Reference in New Issue
Block a user