Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: npm install as rocketchat user #33726

Merged
merged 1 commit into from
Oct 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions apps/meteor/.docker/Dockerfile.debian
Original file line number Diff line number Diff line change
Expand Up @@ -30,21 +30,27 @@ ENV DEPLOY_METHOD=docker \

RUN aptMark="$(apt-mark showmanual)" \
&& apt-get install -y --no-install-recommends g++ make python3 ca-certificates \
&& cd /app/bundle/programs/server \
&& apt-mark auto '.*' > /dev/null \
&& apt-mark manual $aptMark > /dev/null

USER rocketchat

RUN cd /app/bundle/programs/server \
&& npm install \
&& cd npm/node_modules/isolated-vm \
&& npm install \
&& apt-mark auto '.*' > /dev/null \
&& apt-mark manual $aptMark > /dev/null \
&& find /usr/local -type f -executable -exec ldd '{}' ';' \
&& npm cache clear --force

USER root

RUN find /usr/local -type f -executable -exec ldd '{}' ';' \
| awk '/=>/ { print $(NF-1) }' \
| sort -u \
| xargs -r dpkg-query --search \
| cut -d: -f1 \
| sort -u \
| xargs -r apt-mark manual \
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
&& npm cache clear --force
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false

USER rocketchat

Expand Down
Loading