Browse Source

更新 'api/Dockerfilenew'

dev
iris_cx 1 year ago
parent
commit
764327a8cf
  1. 4
      api/Dockerfilenew

4
api/Dockerfilenew

@ -1,4 +1,4 @@
FROM registry.cn-hangzhou.aliyuncs.com/fs-devops/node:12-dev as builder FROM registry.ngaiot.com/base-images/node:12-fs-dev-35 as builder
COPY ./api/ /var/app COPY ./api/ /var/app
WORKDIR /var/app WORKDIR /var/app
EXPOSE 8080 EXPOSE 8080
@ -7,7 +7,7 @@ RUN echo "{\"time\":\"$BUILD_TIMESTAMP\",\"build\": \"$BUILD_NUMBER\",\"revision
RUN npm cache clean -f RUN npm cache clean -f
RUN rm -rf package-lock.json RUN rm -rf package-lock.json
RUN npm install --registry https://nexus.ngaiot.com/repository/fs-npm/ RUN npm install --registry https://nexus.ngaiot.com/repository/fs-npm/
FROM registry.cn-hangzhou.aliyuncs.com/fs-devops/node:12 FROM registry.ngaiot.com/base-images/node:12-fs-prod-40
COPY --from=builder --chown=node /var/app /home/node/app COPY --from=builder --chown=node /var/app /home/node/app
WORKDIR /home/node/app WORKDIR /home/node/app
CMD ["node", "server.js"] CMD ["node", "server.js"]
Loading…
Cancel
Save