mirror of
https://github.com/apotdevin/thunderhub.git
synced 2025-02-23 06:35:05 +01:00
14 lines
378 B
Text
14 lines
378 B
Text
|
# 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;"]
|