docs: unify Ubuntu root /opt PM2 deployment and refresh README

Add docs/ubuntu-server.md; remove Windows and alternate process managers from deployment guides; index strategy, key monitor, TP/SL, breakeven, and replay docs in root README.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-06-04 11:48:54 +08:00
parent 546bc7bcf1
commit 1282293e91
16 changed files with 355 additions and 491 deletions
+11 -12
View File
@@ -19,9 +19,10 @@
安装示例:
```bash
python -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate
pip install flask requests ccxt werkzeug PySocks Pillow
# 推荐在 /opt/crypto_monitor 执行仓库根目录 deploy/setup_env.sh
cd /opt/crypto_monitor/crypto_monitor_binance
source .venv/bin/activate
pip install -r ../requirements.txt
```
页面上的 **「当日资金(交易账户)」** 与 **「可开仓」可用 U** 仅统计 **Binance U 本位永续合约账户**`fetch_balance``swap` / FAPI `assets` 中的 USDT),**不会**再用现货余额顶替。
@@ -46,19 +47,17 @@ pip install flask requests ccxt werkzeug PySocks Pillow
其余变量(登录、企业微信、风控参数、**`AI_PROVIDER` / `OPENAI_*` / `OLLAMA_*`**、数据库路径等)见 **`.env.example` 内注释** 或 `app.py` 顶部默认值。
## 本地运行
## 运行
**WindowsUTF-8 控制台)** 可使用
生产环境使用 **PM2**`ecosystem.config.cjs`)。临时调试
```powershell
.\start_utf8.ps1
```bash
cd /opt/crypto_monitor/crypto_monitor_binance
source .venv/bin/activate
python app.py
```
或直接:
```powershell
python .\app.py
```
环境说明见 [docs/ubuntu-server.md](../docs/ubuntu-server.md)。
默认监听端口由 `.env``APP_PORT` 决定(未设置时多为 `5000`)。