Ver Fonte

Build the frontend assets for the image

Johannes Zellner há 9 anos atrás
pai
commit
80ff86d61b
1 ficheiros alterados com 4 adições e 1 exclusões
  1. 4 1
      Dockerfile

+ 4 - 1
Dockerfile

@@ -6,10 +6,13 @@ ENV PATH /usr/local/node-6.9.5/bin:$PATH
 RUN mkdir -p /app/code
 WORKDIR /app/code
 
+RUN npm install -g browserify
+
 COPY frontend /app/code/frontend/
 COPY backend /app/code/backend/
 COPY start.sh app.js package.json /app/code/
 
-RUN npm install --production
+RUN npm install
+RUN browserify -t vueify -t envify -e ./frontend/js/main.js -o ./frontend/js/bundle.js
 
 CMD [ "/app/code/start.sh" ]