sync: 多文件 | 原因: 本地开发更新

This commit is contained in:
卡若
2026-03-08 17:43:53 +08:00
parent 9ec7692a86
commit 0f6fb134dd

View File

@@ -99,11 +99,14 @@ cd soul/dist && PORT=3006 node server.js
| WECHAT_CERT_PATH / WECHAT_KEY_PATH | 证书路径 | certs/ 下 |
| CORS_ORIGINS | 允许的跨域源 | 含 localhost、soul.quwanzhi.com |
### 3.2 soul-admin 的 API 地址
### 3.2 soul-admin 的 API 地址(本地 vs 部署)
- 正式:`https://soulapi.quwanzhi.com`
- 开发:`https://souldev.quwanzhi.com`(打包时已写死)
- 本机联调:`/etc/hosts` `127.0.0.1 soulapi.quwanzhi.com`,管理后台会访问本机 8080
| 环境 | 配置文件 | API 地址 |
|------|----------|----------|
| 本地开发 `pnpm dev` | `.env.development` | `http://localhost:8080` |
| 部署构建 `pnpm build` | `.env.production` | `https://soulapi.quwanzhi.com` |
**流程**:本地改代码用 `pnpm dev`,会自动请求本机 soul-api部署时执行 `pnpm build`,产物自动用线上 API无需改配置。
---