Fix 'use omit=dev' warning. copy package-lock
This commit is contained in:
parent
b6e2d101eb
commit
5131a630a5
2 changed files with 3 additions and 3 deletions
|
|
@ -30,9 +30,9 @@ RUN set -ex; \
|
|||
rm -rf /var/lib/apt/lists/*;
|
||||
|
||||
RUN mkdir -p /usr/src/app
|
||||
COPY package.json /usr/src/app
|
||||
COPY package* /usr/src/app/
|
||||
|
||||
RUN cd /usr/src/app && npm install --production
|
||||
RUN cd /usr/src/app && npm install --omit=dev
|
||||
|
||||
FROM ubuntu:focal AS final
|
||||
|
||||
|
|
|
|||
|
|
@ -27,6 +27,6 @@ ENTRYPOINT ["/usr/src/app/docker-entrypoint.sh"]
|
|||
|
||||
RUN mkdir -p /usr/src/app
|
||||
COPY / /usr/src/app
|
||||
RUN cd /usr/src/app && npm install --production
|
||||
RUN cd /usr/src/app && npm install --omit=dev
|
||||
RUN ["chmod", "+x", "/usr/src/app/docker-entrypoint.sh"]
|
||||
USER node:node
|
||||
|
|
|
|||
Loading…
Reference in a new issue