提交 6e381a04 作者: 杨大同

更新 Dockerfile-pred

上级 00a18500
流水线 #44574 已取消 于阶段
in 27 秒
# This file is a template, and might need editing before it works on your project. FROM registry-vpc.cn-beijing.aliyuncs.com/qianjia2018/qianjia_public:dist-node
FROM registry-vpc.cn-beijing.aliyuncs.com/qianjia2018/qianjia_public:dist-node as build-stage LABEL QianJia.ZhangPeng <zanpen2000@gmail.com>
WORKDIR /app
COPY package*.json ./ ADD package.json /tmp/package.json
RUN apk update && apk upgrade && \ RUN cd /tmp && npm config set registry http://172.17.3.95:9000/repository/node-public && npm install && npm install pm2 -g
apk add --no-cache bash git openssh RUN mkdir -p /opt/app && cp -a /tmp/node_modules /opt/app/
RUN npm config set registry http://172.17.3.95:9000/repository/node-public && npm install
COPY . . WORKDIR /opt/app
RUN npm run pred ADD . /opt/app
FROM registry-vpc.cn-beijing.aliyuncs.com/qianjia2018/qianjia_public:dist-nginx as production-stage EXPOSE 8009
COPY --from=build-stage /app/dist /usr/share/nginx/html
EXPOSE 80 CMD pm2 start apps.config.js --env pred --no-daemon
CMD ["nginx", "-g", "daemon off;"]
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论