美文网首页
使用Dockerfile构建images

使用Dockerfile构建images

作者: 嘛尼嘛哄 | 来源:发表于2020-01-06 10:19 被阅读0次

使用Dockerfile构建images

FROM node:10

WORKDIR /[imagesworkdir]

Install NPM deps

COPY package.json package.json
COPY package-lock.json package-lock.json

Point to internal npm registry

RUN npm set registry [your custom registry]
RUN npm install
COPY . .

Bundle app source, such as code coverage check, deploy result.

RUN npm run-script build

Start server

EXPOSE 80 8080
CMD ["node", "dist/main.js"]

reference: https://docs.docker.com/engine/reference/builder/

相关文章

网友评论

      本文标题:使用Dockerfile构建images

      本文链接:https://www.haomeiwen.com/subject/wvbhactx.html