Files
blog/infra/gitea/docker-compose.yml
wait4xandGLM-5.3 ddcda54f90 feat(gitea): 部署 gitea 28.2.0 并入库接入草稿
- 容器 gitea/gitea:28.2.0 仅绑 127.0.0.1:13020,管理员 wait4x 经 CLI 创建,
  私有空仓 wait4x/blog 就位(Phase 1 博客源码仓)
- app.ini 种子入库(INSTALL_LOCK 预置,密钥首启生成,快照严禁回覆盖运行时)
- REQUIRE_SIGNIN_VIEW 会 403 匿名 version 端点,与验收冲突已撤,坑记 README
- 凭据不进 git:初始密码并入住主 init-credentials.txt(0600),README 留指引

验证: curl -sf http://127.0.0.1:13020/api/v1/version → {"version":"28.2.0"};
      docker inspect gitea = running;wait4x/blog private+empty 经 API 查证

Co-authored-by: GLM-5.3
2026-10-24 22:09:06 +08:00

21 lines
847 B
YAML

# 入库快照:宿主运行位置 ~/docker_apps/gitea/,内容与本文件一致;改动先改这里再同步过去
services:
gitea:
# 官方 rootful 镜像,锁补丁版本保证可重现;升级=改 tag + pull + up -d
image: gitea/gitea:28.2.0
container_name: gitea
restart: unless-stopped
environment:
# 容器内 git 用户映射到宿主 1000,./data 下不产生 root 属主文件
USER_UID: "1000"
USER_GID: "1000"
TZ: Asia/Shanghai
volumes:
- ./data:/data
# 时区注入双保险(文件+TZ env),避免日志与提交时间戳漂移
- /etc/localtime:/etc/localtime:ro
- /etc/timezone:/etc/timezone:ro
ports:
# 仅绑回环,公网入口由 nginx 反代(见 nginx-git.wait4x.online.conf,接入前不生效)
- "127.0.0.1:13020:3000"