rwadurian/frontend/mining-admin-web/src
hailin 59efdb1f78 fix(mining-admin-web): 修复 API 请求超时和路由问题
问题:
- mining-admin-web 容器与后端服务在不同 Docker 网络, 无法通过公网 IP 回连 (hairpin NAT 失败)
- next.config.js 生产模式强制走 mapi.szaiai.com Kong 网关, 容器内无法访问
- client.ts 使用 NEXT_PUBLIC_API_URL 导致外部 URL 被 build 时内联到客户端包
- mining-service controller 有 mining/ 前缀, 直连模式 rewrite 丢失该前缀

修复:
- next.config.js: 改用 API_GATEWAY_URL 判断路由模式, 未设置则直连后端服务
- next.config.js: mining rewrite 保留 mining/ 前缀匹配 controller 路由
- client.ts: baseURL 固定为 /api, 所有请求统一走 Next.js rewrite 代理
- docker-compose.2.0.yml: 添加 TRADING_SERVICE_URL 和 MINING_SERVICE_URL 环境变量

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-02 01:14:19 -08:00
..
app feat(c2c-bot): rename HOT_WALLET to C2C_BOT_WALLET and change dUSDT to 绿积分 2026-02-01 08:40:45 -08:00
components feat(c2c-bot): 添加C2C Bot管理页面,支持运行时开关和热钱包查看 2026-02-01 04:47:28 -08:00
features feat(c2c-bot): 添加C2C Bot管理页面,支持运行时开关和热钱包查看 2026-02-01 04:47:28 -08:00
lib fix(mining-admin-web): 修复 API 请求超时和路由问题 2026-02-02 01:14:19 -08:00
store fix(mining-admin-web): 修复 React hydration 错误 #418 #423 2026-01-11 20:47:00 -08:00
types fix(frontend): 添加 regionCode 到 SystemAccount 类型 2026-01-21 02:23:35 -08:00