正在显示
1 个修改的文件
包含
15 行增加
和
4 行删除
1 | 1 | FROM node:16-alpine |
2 | 2 | |
3 | -RUN mkdir -p /opt/work/hro/frontend/hro | |
3 | +WORKDIR /opt/work/hro/frontend/hro | |
4 | 4 | |
5 | -COPY . /opt/work/hro/frontend/hro/server/ | |
5 | +COPY package*.json ./ | |
6 | 6 | |
7 | -WORKDIR /opt/work/hro/frontend/hro | |
7 | +COPY . ./server | |
8 | + | |
9 | +RUN apk add --no-cache git | |
10 | + | |
11 | +RUN npm config set registry https://registry.npmmirror.com | |
12 | + | |
13 | +RUN npm install | |
14 | + | |
15 | + | |
16 | +EXPOSE 3000 | |
17 | + | |
18 | +ENV NODE_ENV=production | |
8 | 19 | |
9 | -EXPOSE 3000 | |
\ No newline at end of file | ||
20 | +CMD ["node","server/app.js"] | |
\ No newline at end of file | ... | ... |
请
注册
或
登录
后发表评论