mirror of https://github.com/jumpserver/jumpserver
fix: 修复 ES 存储 config 被修改的问题
parent
bf7c05f753
commit
0e6dbb3e5d
|
@ -85,7 +85,8 @@ class CommandStorage(CommonStorageModelMixin, CommonModelMixin):
|
|||
config = self.config
|
||||
if self.type_es and config.get('INDEX_BY_DATE'):
|
||||
engine_mod = import_module(TYPE_ENGINE_MAPPING[self.type])
|
||||
store = engine_mod.CommandStore(config)
|
||||
# 这里使用一个全新的 config, 防止修改当前的 config
|
||||
store = engine_mod.CommandStore(self.config)
|
||||
store._ensure_index_exists()
|
||||
index_prefix = config.get('INDEX') or 'jumpserver'
|
||||
date = local_now_date_display()
|
||||
|
|
Loading…
Reference in New Issue