feat: 新增 Docker Compose 一键部署(MySQL + 后端 + 前端)

- 新增 docker-compose.yml,按健康检查顺序启动 MySQL 8、Go 后端与 Nginx 前端
- 新增 server/web 多阶段 Dockerfile、nginx 反向代理配置与 .dockerignore
- 后端支持 KENAITO_* 环境变量覆盖配置,新增 /health 健康检查接口
- 补充中英文 README 与 Docker 部署文档、.env.example 环境变量模板
This commit is contained in:
2026-08-27 21:17:10 +08:00
parent 005bd2490c
commit d6a052e0a4
14 changed files with 393 additions and 17 deletions
+18
View File
@@ -0,0 +1,18 @@
# Build stage
FROM node:20-alpine AS build
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm ci --no-audit --no-fund
COPY . .
RUN npm run build
# Runtime stage
FROM nginx:1.27-alpine
COPY nginx.conf /etc/nginx/conf.d/default.conf
COPY --from=build /app/dist /usr/share/nginx/html
EXPOSE 80