dela
|
1b61541ff5
|
feat: 接入 CoinGlass 清算热力图隔离链路
ci / build + vet + guard + race (push) Has been cancelled
|
2026-05-25 16:57:22 +08:00 |
|
dela
|
622ff1d317
|
build: isolate go module proxy setting
|
2026-05-24 21:50:22 +08:00 |
|
dela
|
6f4e7f04cc
|
build: pass module proxy to docker builder
|
2026-05-24 21:40:23 +08:00 |
|
dela
|
542eeefdbd
|
deploy: harden compose harness
|
2026-05-24 21:18:19 +08:00 |
|
dela
|
16f7f00d7b
|
deploy(compose): 修 4 个上生产前的阻断项
为什么:v2.0 代码侧已 ready,但 docker compose up 起来会立刻 panic
(表不存在),且密码硬编码、Binance 直连超时、无 healthcheck。
修复:
1. migrate init container(migrate/migrate:v4.18.1)
- depends_on postgres service_healthy 后执行
- 跑完 up 退出;app depends_on migrate service_completed_successfully
- 表不存在的 race 彻底消除
2. postgres healthcheck(pg_isready)
- interval 5s、retries 10、start_period 10s
- app 不再在 init 期连接失败
3. .env + .env.example(守卫 G9)
- 密码、端口、Binance URL 全部从环境变量读
- POSTGRES_PASSWORD 未设置时 docker-compose 直接报错退出(${VAR:?...} 语法)
- .env 已在 .gitignore,.env.example 留作模板
4. HTTP_PROXY/HTTPS_PROXY/NO_PROXY 透传
- 国内直连 fapi.binance.com 不稳(AGENTS.md §7.5)
- NO_PROXY 默认包含 postgres 容器名,避免本地代理误走
附加:config 卷只读挂载(防容器内意外写入);ports 端口可由
.env 覆盖;postgres 容器名走 docker DNS(替换之前硬编码的
crypto-hermes-postgres)。
验证:python yaml lint 通过;依赖链 postgres healthy →
migrate completed → app start 已确认。docker 在本机不可用,
线上验证留给 commit 9 之后的人工 smoke。
|
2026-05-24 20:59:09 +08:00 |
|