copying build, not dist

This commit is contained in:
Fedor Katurov 2021-04-08 11:40:08 +07:00
parent 7735d11019
commit faed11bb79

View file

@ -1,5 +1,4 @@
# stage1 as builder
WORKDIR /
FROM node:erbium-alpine as builder
COPY package.json yarn.lock ./
RUN yarn
@ -9,6 +8,6 @@ RUN yarn build
FROM nginx:alpine
COPY docker/www/nginx.conf /etc/nginx/nginx.conf
RUN rm -rf /usr/share/nginx/html/*
COPY --from=builder /dist /usr/share/nginx/html
COPY --from=builder /build /usr/share/nginx/html
EXPOSE ${EXPOSE} 80
ENTRYPOINT ["nginx", "-g", "daemon off;"]