thunderhub/client/Dockerfile
2020-03-22 21:16:46 +01:00

14 lines
No EOL
378 B
Docker

# stage: 1
FROM node:11-alpine as react-build
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
COPY . .
RUN yarn install --production=true
RUN yarn build
# stage: 2 — the production environment
FROM nginx:alpine
COPY /config/nginx.conf /etc/nginx/conf.d/default.conf
COPY --from=react-build /usr/src/app/build /usr/share/nginx/html/
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]