Skip to content

Commit 32bfbc6

Browse files
author
ACoolmanTelicent
committed
fix(GHSA-3xgq-45jj-v27): force cross-spawn version
1 parent 32ee382 commit 32bfbc6

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

20/alpine3.20/Dockerfile

+11-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,17 @@ RUN addgroup -g 1000 node \
7575
&& apk del .build-deps \
7676
# smoke tests
7777
&& node --version \
78-
&& npm --version
78+
&& npm --version \
79+
# FORCE correct version of cross-spawn in system
80+
&& mkdir /tmp/npm-install \
81+
&& cd /tmp/npm-install \
82+
&& npm init -y \
83+
&& npm install [email protected] \
84+
# Now move the installed cross-spawn to the target directory
85+
&& cp -R node_modules/cross-spawn /usr/local/lib/node_modules/npm/node_modules/ \
86+
# Clean up
87+
&& cd / \
88+
&& rm -rf /tmp/npm-install
7989

8090
ENV YARN_VERSION 1.22.22
8191

0 commit comments

Comments
 (0)