first commit
This commit is contained in:
+19
@@ -0,0 +1,19 @@
|
||||
# Stufe 1: React-Frontend bauen
|
||||
FROM node:20-alpine AS frontend
|
||||
WORKDIR /fe
|
||||
COPY frontend/package.json ./
|
||||
RUN npm install --no-audit --no-fund
|
||||
COPY frontend/ ./
|
||||
RUN npm run build
|
||||
|
||||
# Stufe 2: FastAPI liefert API und gebautes Frontend aus
|
||||
FROM python:3.12-slim
|
||||
WORKDIR /app
|
||||
COPY backend/requirements.txt ./
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
COPY backend/app ./app
|
||||
COPY backend/data ./data
|
||||
COPY --from=frontend /fe/dist ./static
|
||||
ENV AW_DB=/db/aw.db
|
||||
EXPOSE 8000
|
||||
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8000"]
|
||||
Reference in New Issue
Block a user