虚拟化front备份
Dockerfile:
FROM node:8-alpine ENV BACKEND_URL=http://unknown
ENV BACKEND_Ws_URL=http://unknown
# 1.1 先安装依赖 WORKDIR /app COPY package.json /app/ COPY package-lock.json /app/ # 如果ChromeDriver被墙了 RUN npm install chromedriver --chromedriver_cdnurl=http://cdn.npm.taobao.org/dist/chromedriver --verbose \ && npm install --registry=https://registry.npm.taobao.org --verbose #RUN npm install --registry=https://registry.npm.taobao.org --verbose COPY . /app EXPOSE 8080 CMD npm run start
.dockerignore :
.git .svn **/node_modules **/dist