Skip to content

Commit

Permalink
Avoid the direct dependency to node-gyp since it's now bundled with n…
Browse files Browse the repository at this point in the history
…pm (#627)
  • Loading branch information
azatsarynnyy authored Sep 9, 2024
1 parent cc33795 commit a6c29c2
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 660 deletions.
24 changes: 0 additions & 24 deletions devspaces-code/build/dockerfiles/brew.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -113,18 +113,6 @@ RUN git init .; \
RUN sed -i -r -e '/function yarnInstall/ !s|^[^#]*yarnInstal|//&|' build/npm/postinstall.js
# ... and run the dependencies installation manually for each sub-package listed in the 'code/build/npm/dirs.js' (except the 'test' folder).

# install node-gyp - workaround for `yarn global add node-gyp`, since installing it
# globally it tries to fetch it from outside. So, we install locally the module
# that has node-gyp dependency, and then put it's node_modules to yarns global modules
RUN cd $REMOTE_SOURCES_DIR/devspaces-images-code/app/devspaces-code/cachito \
&& yarn \
&& mkdir -p $(yarn global dir) && cp -r $REMOTE_SOURCES_DIR/devspaces-images-code/app/devspaces-code/cachito/node_modules/. $(yarn global dir)/node_modules \
&& mkdir -p $(yarn global bin) && ln -s $(yarn global dir)/node_modules/.bin/node-gyp $(yarn global bin)/node-gyp \
&& ls -l $(yarn global bin) \
&& ls -l $(yarn global dir)/node_modules/.bin \
&& which node-gyp \
&& node-gyp version

# Cachito clears all project's '.yarnrc' files, To make sure yarn is configured to the local Nexus.
# To avoid any possible issues, like failure of build because of missing 'ms_build_id', or 'target' properties,
# or @parcel/watcher skipping compilation because of missing 'build_from_source' flag.
Expand Down Expand Up @@ -331,18 +319,6 @@ RUN git init .; \
RUN sed -i -r -e '/function yarnInstall/ !s|^[^#]*yarnInstal|//&|' build/npm/postinstall.js
# ... and run the dependencies installation manually for each sub-package listed in the 'code/build/npm/dirs.js' (except the 'test' folder).

# install node-gyp - workaround for `yarn global add node-gyp`, since installing it
# globally it tries to fetch it from outside. So, we install locally the module
# that has node-gyp dependency, and then put it's node_modules to yarns global modules
RUN cd $REMOTE_SOURCES_DIR/devspaces-images-code/app/devspaces-code/cachito \
&& yarn \
&& mkdir -p $(yarn global dir) && cp -r $REMOTE_SOURCES_DIR/devspaces-images-code/app/devspaces-code/cachito/node_modules/. $(yarn global dir)/node_modules \
&& mkdir -p $(yarn global bin) && ln -s $(yarn global dir)/node_modules/.bin/node-gyp $(yarn global bin)/node-gyp \
&& ls -l $(yarn global bin) \
&& ls -l $(yarn global dir)/node_modules/.bin \
&& which node-gyp \
&& node-gyp version

# Cachito clears all project's '.yarnrc' files, To make sure yarn is configured to the local Nexus.
# To avoid any possible issues, like failure of build because of missing 'ms_build_id', or 'target' properties,
# or @parcel/watcher skipping compilation because of missing 'build_from_source' flag.
Expand Down
1 change: 0 additions & 1 deletion devspaces-code/cachito/README.md

This file was deleted.

8 changes: 0 additions & 8 deletions devspaces-code/cachito/package.json

This file was deleted.

Loading

0 comments on commit a6c29c2

Please sign in to comment.