2024-11-10 16:27:50 +08:00
|
|
|
FROM node:22-alpine AS node
|
|
|
|
|
|
|
|
WORKDIR /app
|
|
|
|
|
|
|
|
COPY web ./web
|
|
|
|
|
|
|
|
RUN cd web && npm install && npm run build
|
|
|
|
|
2024-02-19 20:36:26 +08:00
|
|
|
FROM python:3.10.13-slim
|
2024-11-10 16:27:50 +08:00
|
|
|
|
2024-02-07 00:07:55 +08:00
|
|
|
WORKDIR /app
|
2023-03-24 19:58:27 +08:00
|
|
|
|
2024-02-07 00:07:55 +08:00
|
|
|
COPY . .
|
2023-03-24 19:58:27 +08:00
|
|
|
|
2024-11-10 16:27:50 +08:00
|
|
|
COPY --from=node /app/web/dist ./web/dist
|
|
|
|
|
2024-02-21 21:44:07 +08:00
|
|
|
RUN apt update \
|
|
|
|
&& apt install gcc -y \
|
2024-03-07 15:55:02 +08:00
|
|
|
&& python -m pip install -r requirements.txt \
|
|
|
|
&& touch /.dockerenv
|
|
|
|
|
2024-02-08 13:40:25 +08:00
|
|
|
CMD [ "python", "main.py" ]
|