Fix position flicker, drop futures cooloff, prioritize startup display.
Preserve trading state when CTP memory is empty, bootstrap equity/positions on page load, stabilize risk status from DB monitors, and remove app-layer manual close cooling periods. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+17
-4
@@ -1,21 +1,34 @@
|
||||
const path = require("path");
|
||||
const fs = require("fs");
|
||||
|
||||
const ROOT = __dirname;
|
||||
const venvCandidates = [
|
||||
path.join(ROOT, "venv", "bin", "python"),
|
||||
path.join(ROOT, "venv", "Scripts", "python.exe"),
|
||||
];
|
||||
const interpreter = venvCandidates.find((p) => fs.existsSync(p)) || "python3";
|
||||
|
||||
module.exports = {
|
||||
apps: [
|
||||
{
|
||||
name: "qihuo",
|
||||
script: "app.py",
|
||||
cwd: "/opt/qihuo",
|
||||
interpreter: "/opt/qihuo/venv/bin/python",
|
||||
cwd: ROOT,
|
||||
interpreter,
|
||||
instances: 1,
|
||||
autorestart: true,
|
||||
watch: false,
|
||||
max_memory_restart: "8192M",
|
||||
env: {
|
||||
NODE_ENV: "production",
|
||||
LANG: "zh_CN.UTF-8",
|
||||
LC_ALL: "zh_CN.UTF-8",
|
||||
LC_CTYPE: "zh_CN.UTF-8",
|
||||
QIHUO_STARTUP_WORKERS: "8",
|
||||
QIHUO_MEMORY_MB: "8192",
|
||||
},
|
||||
error_file: "/opt/qihuo/logs/pm2-error.log",
|
||||
out_file: "/opt/qihuo/logs/pm2-out.log",
|
||||
error_file: path.join(ROOT, "logs", "pm2-error.log"),
|
||||
out_file: path.join(ROOT, "logs", "pm2-out.log"),
|
||||
time: true,
|
||||
},
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user