npm -v):node -v): 10.14.1node -p process.versions):node -p process.platform): linuxnode -p process.arch): amd64node -p "require('node-sass').info"):npm ls node-sass): whatever one os.js usesI was installing this as root with --unsafe-perm=true --allow-root because I'm installing this in a chroot.
gyp verb download contents checksum {"node-v11.3.0-headers.tar.gz":"ec21aa45c8790e3ab8df531f760458222237a3b8fe61aeef0532d7a11d0aa2bd"}
gyp verb validating download checksum for node-v11.3.0-headers.tar.gz (ec21aa45c8790e3ab8df531f760458222237a3b8fe61aeef0532d7a11d0aa2bd == ec21aa45c8790e3ab8df531f760458222237a3b8fe61aeef0532d7a11d0aa2bd)
gyp verb get node dir target node version installed: 11.3.0
gyp verb build dir attempting to create "build" dir: /opt/os.js/node_modules/node-sass/build
gyp ERR! configure error
gyp ERR! stack Error: EACCES: permission denied, mkdir '/opt/os.js/node_modules/node-sass/build'
gyp ERR! System Linux 4.19.4-arch1-1-ARCH
gyp ERR! command "/usr/bin/node" "/opt/os.js/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /opt/os.js/node_modules/node-sass
gyp ERR! node -v v11.3.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
npm WARN [email protected] requires a peer of [email protected] but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall 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! /root/.npm/_logs/2018-12-09T03_49_39_632Z-debug.log
try npm install --unsafe-perm
already did
The log say v11.3.0 rather than 10.14.1. Sorry, but we're not going to be able to troubleshoot an issue with os.js, I suggest you file an issue over there or on SO.
already did
Hi. I am having the same problem. Did you find any answer??
No fix has been found.
i solved, these are the scripts to run as root user. I am using Fedora28 and node version 10.12.2. Make sure to do these scripts as root user because it didn't work with sudo. I fixed the same bug on two of my projects. These scripts worked for me.
$ rm -rf node_modules/ package-log.json
$ npm cache clean --force
$ npm install node-sass --unsafe-perm
$ npm install --unsafe-perm
Yeah but this is being done on a fresh directory/package
i solved, these are the scripts to run as root user. I am using Fedora28 and node version 10.12.2. Make sure to do these scripts as root user because it didn't work with sudo. I fixed the same bug on two of my projects. These scripts worked for me.
$ rm -rf node_modules/ package-log.json
$ npm cache clean --force
$ npm install node-sass --unsafe-perm
$ npm install --unsafe-perm
it works,thx
Most helpful comment
i solved, these are the scripts to run as root user. I am using Fedora28 and node version 10.12.2. Make sure to do these scripts as root user because it didn't work with sudo. I fixed the same bug on two of my projects. These scripts worked for me.
$ rm -rf node_modules/ package-log.json
$ npm cache clean --force
$ npm install node-sass --unsafe-perm
$ npm install --unsafe-perm