Add interactive deploy manager with install, uninstall, and update menus.
Provides curl-friendly manage.sh so production servers can bootstrap without a prior clone, then configure API and risk settings in the browser. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+12
-3
@@ -38,11 +38,20 @@ apt install -y python3.12-venv
|
||||
|
||||
### 2.2 一键创建各目录 venv
|
||||
|
||||
**推荐**(新服务器一条命令):
|
||||
|
||||
```bash
|
||||
curl -fsSL https://git.bz121.com/dekun/crypto_monitor/raw/branch/main/deploy/manage.sh | bash
|
||||
# 菜单选 1) 一键部署
|
||||
```
|
||||
|
||||
或已 clone 后:
|
||||
|
||||
```bash
|
||||
cd /opt/crypto_monitor
|
||||
bash deploy/manage.sh
|
||||
# 或仅建环境:
|
||||
bash deploy/setup_env.sh --install-system-deps
|
||||
# 或已是 root 且已装 venv 包:
|
||||
bash deploy/setup_env.sh
|
||||
```
|
||||
|
||||
完成后各目录使用 **`.venv/bin/python`** 运行 `app.py` / `hub.py`;**PM2 的 ecosystem 脚本已指向该解释器**.
|
||||
@@ -163,7 +172,7 @@ curl -sS http://127.0.0.1:5100/api/monitor/board | head
|
||||
|
||||
| 文档 | 内容 |
|
||||
|------|------|
|
||||
| [deploy/README.md](../deploy/README.md) | `setup_env.sh` 参数说明 |
|
||||
| [deploy/README.md](../deploy/README.md) | `manage.sh` 一键部署;`setup_env.sh` 参数 |
|
||||
| [备份与恢复.md](../备份与恢复.md) | 数据库与 `.env` 备份 |
|
||||
| 各 `crypto_monitor_*/部署文档.md` | 交易所 SOCKS,`.env`,PM2 细节 |
|
||||
| [manual_trading_hub/部署文档.md](../manual_trading_hub/部署文档.md) | 中控 PM2,端口,反代 |
|
||||
|
||||
Reference in New Issue
Block a user