twenty/infra/prod/front/Dockerfile

26 lines
420 B
Docker
Raw Normal View History

FROM node:18.16.0-alpine as build
2023-04-13 13:40:44 +03:00
ARG REACT_APP_SERVER_BASE_URL
ARG REACT_APP_SERVER_AUTH_URL
ARG REACT_APP_SERVER_FILES_URL
2023-04-14 12:52:12 +03:00
COPY ./packages/ /app/packages
2023-04-13 13:40:44 +03:00
WORKDIR /app/front
COPY ./front .
2023-06-14 18:26:14 +03:00
RUN yarn install
RUN yarn build
2023-04-13 13:40:44 +03:00
COPY ./infra/prod/front/serve.json ./build
FROM node:18.16.0-alpine as front
WORKDIR /app/front
COPY --from=build /app/front/build ./build
2023-06-14 18:11:12 +03:00
RUN yarn global add serve
2023-04-13 13:40:44 +03:00
CMD ["serve", "build"]