-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
globally installed packages have incorrect permissions (EACCES) #1060
Comments
Not gulp specific, globally installed packages are not usable because of incorrect permissions: Do you want to request a feature or report a bug? What is the current behavior?
If the current behavior is a bug, please provide the steps to reproduce. What is the expected behavior? Please mention your node.js, yarn and operating system version. |
Can confirm this bug on Arch Linux
|
Have this bug on yarn 0.17.8 , Node 6.9.1, Ubuntu.
Then as non-root user:
Looks like #1344 was meant to fix this but only fixed the perrmissions on accessing the root package, not its dependencies. 😢 |
I do confirm the bug trying to The error:
|
I'm having the same issue.
|
After the upgrade to yarn 0.18.1, I don't have this issue anymore. |
Same here when using Vagrant and installing globally. Environment
Error
|
Looks like I spoke too soon. The upgrade may have fixed that particular installation, but a fresh install still has this issue. |
Also seeing the bug with yarn global v0.18.1. A workaround would be to manually give read access to everybody with: sudo chmod a+r -R /usr/local/share/.config/yarn/global/ |
I have to say that I tried to repeat the steps in my previous comment, after upgrading to yarn 0.18.1, i.e.
After the upgrade the commands run without a problem (no EACCES: permission error) |
thank you @PowerKiKi ,I solved it |
I have tried with
The problem is still present. I have clean the cache and after fetching
|
Starting from scratch with yarn 0.21.3 and still getting this error. It seems to me that there is enough people who reported this to consider the issue "confirmed" (and thus remove the "needs confirmation") |
The error still lingers in yarn
|
@soredake Please add a reference to the fix if you confirm this is solved. Otherwise, please add some explanation of closure or reopen if it was a mistake. |
PLEASE. DO. SOMETHING. @bestander @soredake |
Let's reopen this for now |
I guess this is related with $ yarn --version
v0.24.5
$ yarn global add yo
$ yo
/usr/local/share/.config/yarn/global/node_modules/mkdirp/index.js:90
throw err0;
^
Error: EACCES: permission denied, mkdir '/root/.config'
at Object.fs.mkdirSync (fs.js:894:18)
at sync (/usr/local/share/.config/yarn/global/node_modules/mkdirp/index.js:71:13)
at Function.sync (/usr/local/share/.config/yarn/global/node_modules/mkdirp/index.js:77:24)
at Configstore.get (/usr/local/share/.config/yarn/global/node_modules/configstore/index.js:38:13)
at Configstore (/usr/local/share/.config/yarn/global/node_modules/configstore/index.js:27:44)
at new Insight (/usr/local/share/.config/yarn/global/node_modules/insight/lib/index.js:37:34)
at Object.<anonymous> (/usr/local/share/.config/yarn/global/node_modules/yo/lib/cli.js:172:11)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32) |
If someone can add a repro step that would help a lot. |
@bestander I think you're right. I had the same problem. I had yarn installed through npm. I uninstalled yarn and gulp: I then installed gulp 4 using yarn: |
This issue appears to me on OSX if yarn (0.23.1) has been already installed with brew |
Closing since this should be resolved in the recent versions of Yarn. Feel free to reopen with a repro script if it is still broken. |
brew install yarn --without-node This is worked for me. |
Do you want to request a feature or report a bug?
bug
What is the current behavior?
EACCES
If the current behavior is a bug, please provide the steps to reproduce.
sudo npm i -g yarn
sudo yarn global add gulp
gulp
What is the expected behavior?
correct permissions
Please mention your node.js, yarn and operating system version.
Node v4.4.6
Yarn 0.15.1
Gentoo Stable
The text was updated successfully, but these errors were encountered: