This repository has been archived on 2021-03-10. You can view files and clone it, but cannot push or open issues or pull requests.
perktree/Dockerfile-frontend

21 lines
352 B
Docker

# vim: set ft=dockerfile :
# Stage 1 (Bundling)
FROM node:alpine as builder
COPY frontend /app
WORKDIR /app
RUN set -ex \
&& apk add --no-cache yarn \
&& yarn install \
&& yarn run build
# Stage 2 (Packaging)
FROM nginx:alpine
COPY --from=builder /app/dist /app
COPY nginx.conf /etc/nginx/conf.d
RUN rm /etc/nginx/conf.d/default.conf
EXPOSE 80