I run npm command on Ubuntu and get permission denied
sudo npm install node-sass
EACCES: permission denied, access '/node_modules/node-sass'
I try to run it as a root user or with sudo and as global.
The project folder has public(777) access.
- nodejs version - v10.8.0
- npm version - 6.3.0
Also, the unsafe package does not solve the problem
sudo npm install --unsafe-perm node-sass
fixing-npm-permissions don't solve
https://docs.npmjs.com/getting-started/fixing-npm-permissions
I have had this problem before, it has to do with your package.lock file and below are the steps which I followed.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.