mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 08:36:12 +01:00
Dockerfiles: reduce image size (#12702)
This commit is contained in:
@@ -31,7 +31,8 @@ RUN groupadd --gid ${GID} ${USER} \
|
||||
|
||||
USER ${USER}
|
||||
|
||||
RUN npm install --omit=dev
|
||||
RUN npm install --omit=dev \
|
||||
&& rm -rf .npm
|
||||
# TODO: generate lockfiles for each package manager
|
||||
## pnpm import \
|
||||
|
||||
|
||||
@@ -38,7 +38,8 @@ COPY --from=git --chown=${USER}:${USER} /usr/src/app/install/package.json /usr/s
|
||||
|
||||
USER ${USER}
|
||||
|
||||
RUN npm install
|
||||
RUN npm install \
|
||||
&& rm -rf .npm
|
||||
|
||||
FROM node:lts-slim AS final
|
||||
|
||||
|
||||
Reference in New Issue
Block a user