I am trying to install a npm module with:
sudo npm install -g now
However, when I try that, I get a warning:
Warning! Please try installing Now CLI again with the
--unsafe-perm
option.
Example:npm i -g --unsafe-perm now
This unsafe permission worries me, and I want to make it clear whether I need to follow it to fix the warning, or I can ignore it?
The explanation at https://docs.npmjs.com/misc/config#unsafe-perm doesn't really tell much, for me. This commented from sam-github on Mar 30, 2016 explains much more clearly about the implication.
However, even after reading the two several times, I'm still unclear what --unsafe-perm
is doing, and what's the implication. So,
- Default: false if running as root
- Set to true to suppress the UID/GID switching when running package scripts.
Is the above two "running" telling about the same thing or different things? If it the same thing, then is it the install time or run time?
All I want is to be able to
- install it
- and let anyone in my system able to use it, with the least security risk
so what should I do?