添加 Dockerfile + Gitea CI(构建镜像→更新yaml→ArgoCD sync)
ci / docker (push) Failing after 54s

This commit is contained in:
2026-08-13 06:40:21 +08:00
parent ca00686d91
commit 414c07399f
3 changed files with 108 additions and 0 deletions
+22
View File
@@ -0,0 +1,22 @@
# Stage 1: Build Vue.js frontend
FROM node:22-alpine AS frontend-builder
WORKDIR /build
COPY frontend/package.json frontend/package-lock.json ./
RUN npm ci
COPY frontend/ ./
RUN npm run build
# Stage 2: Runtime
FROM python:3.12-slim
WORKDIR /app
COPY backend/requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY backend/ .
# Copy built frontend (FastAPI serves as static)
COPY --from=frontend-builder /build/dist/ /app/static/
EXPOSE 8000
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]