zepar-release-form/Dockerfile

23 lines
424 B
Docker

FROM node:10-alpine as builder
ENV WORKDIR=/app/bin/zepar
COPY . ${WORKDIR}
WORKDIR ${WORKDIR}
RUN npm config set registry "https://registry.npm.taobao.org"\
&& npm install
RUN npm run build
FROM openresty/openresty
COPY --from=builder /app/bin/zepar/dist /usr/local/openresty/nginx/html
COPY --from=builder /app/bin/zepar/nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]