front.Dockerfile 306 B

12345678910111213141516
  1. FROM nginx:1.15.10-alpine
  2. RUN apk add yarn
  3. RUN mkdir app
  4. COPY . /app
  5. WORKDIR /app
  6. RUN yarn install
  7. RUN yarn run app:build
  8. RUN ["rm", "-r", "/usr/share/nginx/html"]
  9. RUN ["mv", "/app/dist", "/usr/share/nginx/html"]
  10. RUN ["chmod", "775", "-R", "/usr/share/nginx/html"]
  11. CMD ["nginx", "-g", "daemon off;"]