mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-17 07:49:01 +00:00
Bugfix (#2506)
* [Update] 增加清理celery日志 * [Update] 修复两周前会话命令数量系那是问题 * [Update] 修复两周前会话命令数量系那是问题 * [Update] 修改结构 * [Update] 添加datatable失败的日志 * [Update] 转换配置文件格式 * [Update] 添加traceback
This commit is contained in:
@@ -233,6 +233,7 @@ class AdHoc(models.Model):
|
||||
history.summary = summary
|
||||
return raw, summary
|
||||
except Exception as e:
|
||||
logger.error(e, exc_info=True)
|
||||
return {}, {"dark": {"all": str(e)}, "contacted": []}
|
||||
finally:
|
||||
history.date_finished = timezone.now()
|
||||
|
@@ -81,6 +81,8 @@ def clean_celery_tasks_period():
|
||||
settings.CELERY_LOG_DIR, expire_days
|
||||
)
|
||||
subprocess.call(command, shell=True)
|
||||
command = "echo > {}".format(os.path.join(settings.LOG_DIR, 'celery.log'))
|
||||
subprocess.call(command, shell=True)
|
||||
|
||||
|
||||
@shared_task
|
||||
|
Reference in New Issue
Block a user