angular-seed icon indicating copy to clipboard operation
angular-seed copied to clipboard

Install on Red Hat Enterprise Linux Server release 6.5

Open paultanner opened this issue 11 years ago • 3 comments

npm install (as root) on this system produces this warning.

npm WARN cannot run in wd [email protected] bower install (wd=/root/angular-seed)

it seems to be more than a warning as no server appears on the chosen port Paul

paultanner avatar Sep 01 '14 15:09 paultanner

Can you try installing bower globally and running it directly:

npm install -g bower
bower install

(You may need to do the npm install with a sudo)

petebacondarwin avatar Sep 01 '14 19:09 petebacondarwin

Copied this answer over from http://stackoverflow.com/questions/18136746/npm-install-failed-with-cannot-run-in-wd


The documentation ( http://www.npmjs.org/doc/misc/npm-scripts.html#USER ) says (also http://www.npmjs.org/doc/README.html#Permissions-when-Using-npm-to-Install-Other-Stuff ):

If npm was invoked with root privileges, then it will change the uid to the user account or uid specified by the user config, which defaults to nobody. Set the unsafe-perm flag to run scripts with root privileges.

Your options are:

Run npm install with the --unsafe-perm flag:

[sudo] npm install --unsafe-perm Add the unsafe-perm flag to your package.json:

"config": { "unsafe-perm":true } Don't use the preinstall script to install global modules, install them separately and then run the regular npm install without root privileges:

sudo npm install -g coffee-script node-gyp npm install


paulbhartzog avatar Nov 18 '14 15:11 paulbhartzog

Did this work for anyone? Seems like it still isn't working for me.

pgerochi avatar Jul 27 '15 01:07 pgerochi