Dockerfile 420 B

12345678910111213141516171819
  1. FROM node:12
  2. # make the 'app' folder the current working directory
  3. WORKDIR /app
  4. # copy both 'package.json' and 'package-lock.json' (if available)
  5. COPY package*.json ./
  6. # install project dependencies
  7. RUN npm install
  8. # copy project files and folders to the current working directory (i.e. 'app' folder)
  9. COPY . .
  10. # build app for production with minification
  11. RUN npm run serve
  12. EXPOSE 8080
  13. CMD [ "npm", "run", "serve"]