Strapi installation fails due to blocked npm/github repo, is there any other offline way to setup strapi

Hi Team,

im installing strapi on centos 7 server, in our org access to npm & github repo is blocked, is there another way to install starapi ?

info sharp Downloading https://github.com/lovell/sharp-libvips/releases/download/v8.10.0/libvips-8.10.0-linux-x64.tar.br
ERR! sharp tunneling socket could not be established, statusCode=403
info sharp Attempting to build from source via node-gyp but this may fail due to the above error
info sharp Please see https://sharp.pixelplumbing.com/install for required dependencies
make: Entering directory /home/centos/test1/node_modules/sharp/build' TOUCH Release/obj.target/libvips-cpp.stamp CC(target) Release/obj.target/nothing/node_modules/node-addon-api/nothing.o AR(target) Release/obj.target/node_modules/node-addon-api/nothing.a COPY Release/nothing.a CXX(target) Release/obj.target/sharp/src/common.o ../src/common.cc:24:22: fatal error: vips/vips8: No such file or directory #include <vips/vips8> ^ compilation terminated. make: *** [Release/obj.target/sharp/src/common.o] Error 1 make: Leaving directory /home/centos/test1/node_modules/sharp/build’
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/home/centos/node-v12.18.4-linux-x64/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
gyp ERR! System Linux 3.10.0-1127.18.2.el7.x86_64
gyp ERR! command “/home/centos/node-v12.18.4-linux-x64/bin/node” “/home/centos/node-v12.18.4-linux-x64/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js” “rebuild”
gyp ERR! cwd /home/centos/test1/node_modules/sharp
gyp ERR! node -v v12.18.4
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.1.2 (node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.3: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“linux”,“arch”:“x64”})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.2.7 (node_modules/watchpack-chokidar2/node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“linux”,“arch”:“x64”})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.2.7 (node_modules/webpack-dev-server/node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“linux”,“arch”:“x64”})
npm WARN @buffetjs/utils@3.3.1 requires a peer of yup@^0.27.0 but none is installed. You must install peer dependencies yourself.
npm WARN bootstrap@4.5.3 requires a peer of jquery@1.9.1 - 3 but none is installed. You must install peer dependencies yourself.
npm WARN strapi-connector-bookshelf@3.2.3 requires a peer of knex@^0.20.0 but none is installed. You must install peer dependencies yourself.

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sharp@0.26.0 install: (node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sharp@0.26.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/centos/.npm/_logs/2020-10-14T12_07_46_464Z-debug.log

@Parag_Borle I believe I redirected here to the forums from another issue or discussion elsewhere (and can’t seem to find it)

If I remember correctly I believe I mentioned the issue is coming from sharp and for some reason it’s not pulling the pre-compiled binaries and it attempting to construct the libvips binary from the source code.

In your case access to a GitHub repo will be required and as NPM is now owned by GitHub/Microsoft I believe you will need to contact your Security Operations team and apply an exception here. Going forward in the ecosystem I believe GitHub intends to push more and more packages over to their packages system and slowly phase out NPM.

Hi Derrick,

i went through your reply, was thinking there might be some other way, of installing strapi as our organisation security team will not allow access to github & Npm repo. it would be helpful if you suggest us some other way, offline install or something similar to that.

To my knowledge there is no other way, that issue doesn’t come from Strapi but one of our dependencies, Sharp: GitHub - lovell/sharp: High performance Node.js image processing, the fastest module to resize JPEG, PNG,

That will need to be something you explore with them in this case.