2022-05-03 20:58:19 +02:00
|
|
|
FROM node:16.15-alpine as build
|
2022-05-03 18:21:11 +02:00
|
|
|
WORKDIR /app
|
|
|
|
ENV PATH /app/node_modules/.bin:$PATH
|
|
|
|
COPY package*.json ./
|
|
|
|
RUN yarn install
|
|
|
|
COPY . ./
|
|
|
|
RUN yarn build
|
|
|
|
|
|
|
|
# production environment
|
|
|
|
FROM nginx:stable-alpine
|
|
|
|
COPY --from=build /app/build /usr/share/nginx/html
|
|
|
|
EXPOSE 80
|
|
|
|
CMD ["nginx", "-g", "daemon off;"]
|