背景:此前误将宿主端口冲突当作新建 compose 服务的理由,实际应按技术架构使用本机已有 PostgreSQL/Redis。 改动: - 删除 lingxi-pg / lingxi-redis 容器及数据卷,不再另起数据库; - DATABASE_URL 改回 127.0.0.1:5432/lingxi,REDIS_URL 改回 127.0.0.1:6379; - 在已有 docker-postgres-1 中创建 lingxi 库并执行迁移/seed; - compose 仅保留无法拉取镜像的 S3 兼容服务; - README、A0 报告同步依赖来源。 影响面:仅本地开发依赖与文档;代码/接口/数据模型不变。 回滚方式:git revert 本提交,并按旧 compose 重新初始化(不推荐)。 验证:migrate deploy、db:seed、test:int、pnpm ci:local(85.9s)全部通过。
This commit is contained in:
1 parent
68b5ca20f4
commit
620cb93a46
4 files changed
+19
-55
No files matched your search
+4
-3
@@ -1,16 +1,17 @@
|
||||
# 灵犀 · 环境变量示例(入库,禁止写真实密钥)
|
||||
# 使用:cp .env.example .env.local(工程规范 09 ENV-09)
|
||||
# 注意:本地 compose 的宿主端口为 15432/16379/19000/19001,避免与本机既有 PG/Redis 冲突。
|
||||
# 注意:本地 PostgreSQL/Redis 复用本机已有 Docker 服务(127.0.0.1:5432 / 6379);
|
||||
# S3 兼容服务由 infra/docker-compose.dev.yaml 提供(19000/19001)。
|
||||
|
||||
# ---------- 运行环境 ----------
|
||||
NODE_ENV=development
|
||||
LOG_LEVEL=debug
|
||||
|
||||
# ---------- 数据库(PostgreSQL 18) ----------
|
||||
DATABASE_URL=postgresql://postgres:postgres@127.0.0.1:15432/lingxi?schema=public
|
||||
DATABASE_URL=postgresql://postgres:postgres@127.0.0.1:5432/lingxi?schema=public
|
||||
|
||||
# ---------- Redis(7.4) ----------
|
||||
REDIS_URL=redis://127.0.0.1:16379
|
||||
REDIS_URL=redis://127.0.0.1:6379
|
||||
|
||||
# ---------- 对象存储(MinIO,S3 协议) ----------
|
||||
S3_ENDPOINT=http://127.0.0.1:19000
|
||||
|
||||
Reference in new issue
Block a user