nervmag/Dockerfile

14 lines
322 B
Docker
Raw Normal View History

2018-11-16 18:16:35 +01:00
# Stage 1 - the build process
FROM node:alpine as build-deps
WORKDIR /usr/src/app
COPY *.js *.json yarn.lock ./
COPY public ./public/
COPY src ./src/
RUN yarn && \
yarn build && \
yarn cache clean
# Stage 2 - the production environment
FROM nginx:alpine
COPY --from=build-deps /usr/src/app/dist /usr/share/nginx/html