From 2032670065e7ae27e77c5e74b8c46008f0e864b5 Mon Sep 17 00:00:00 2001 From: Jussi Hallila Date: Mon, 4 Sep 2023 17:06:49 +0200 Subject: [PATCH] Manually remove tough-cookie dependency so we can remove false positive security alerts from the image and satisfy automatic scanners... --- dockerfiles/Dockerfile | 4 ++++ dockerfiles/base.Dockerfile | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/dockerfiles/Dockerfile b/dockerfiles/Dockerfile index 9c41929..4710046 100644 --- a/dockerfiles/Dockerfile +++ b/dockerfiles/Dockerfile @@ -14,6 +14,10 @@ RUN npm install --global snyk-broker RUN rm -rf /home/node/.npm-global/lib/node_modules/snyk-broker/node_modules/setheader/node_modules/debug +RUN rm -rf /home/node/.npm-global/lib/node_modules/snyk-broker/node_modules/tough-cookie +RUN npm i -g tough-cookie@4.1.3 +RUN mv /home/node/.npm-global/lib/node_modules/tough-cookie /home/node/.npm-global/lib/node_modules/snyk-broker/node_modules + FROM roadiehq/broker:base ENV PATH=$PATH:/home/node/.npm-global/bin COPY --from=base /home/node/.npm-global /home/node/.npm-global diff --git a/dockerfiles/base.Dockerfile b/dockerfiles/base.Dockerfile index 97ce8fd..2cc05f5 100644 --- a/dockerfiles/base.Dockerfile +++ b/dockerfiles/base.Dockerfile @@ -8,7 +8,7 @@ RUN groupadd --gid 1000 node \ && useradd --uid 1000 --gid node --shell /bin/bash --create-home node \ && apt update && apt upgrade -y && apt install gpg curl xz-utils -y -ENV NODE_VERSION 18.16.1 +ENV NODE_VERSION 18.17.1 RUN ARCH= && dpkgArch="$(dpkg --print-architecture)" \ && case "${dpkgArch##*-}" in \