-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
After 20240403.1.0
, global install of specific npm version fails with "permission denied, mkdir '/usr/local/share/man/man5'"
#9644
Comments
Related, but pnpm has also started having sporadic problems that only happen on this new image version, and it's breaking DefinitelyTyped: https://github.com/DefinitelyTyped/DefinitelyTyped/actions/runs/8587816469/job/23531927867?pr=69212 |
This also broke TypeScript's nightly publish: https://github.com/microsoft/TypeScript/actions/runs/8586934300/job/23529969314 |
Reran a few times and got the old image again; it passed on the old image: https://github.com/jakebailey/hereby/actions/runs/8585240094/job/23532442215 But another rerun failed on the new one: https://github.com/jakebailey/hereby/actions/runs/8585240094/job/23532442281 This seems to be related to the bump to the global npm from 10.2.4 to 10.5.0. |
All in all, though, I don't understand why the image update broke things; in all of these cases the install came after setup-node, so why is npm even 10.x on the Node 12 examples? Shouldn't PATH have old npm? (I am unfortunately not actually at a real machine so have not had a chance to test this all) And yet, it sometimes works? https://github.com/microsoft/TypeScript/actions/runs/8586651231/job/23529361501 |
I think I see a pattern; on the latest runner image, if setup-node runs without check-latest, the globally installed node is used and a global install of npm fails. For some reason, the old runner image did not break with this? |
/usr/share/man permission has not changed in the images between version, + we do not have man5 subduer at all, so it looks like a big in nom/node, or might be not a big but something changed |
Hey @jakebailey! |
I did a bunch of testing, and the particular bad situation is:
I tried instead using Testing every version between 10.2.4 and 10.5.0, it looks like 10.4.0 is the point at which this behavior changed. Past that, it's impossible for me to tell based on npm's commits/changelog. It's pretty unfortunate that |
I'm going to close this issue as an external one. I suppose that most Node actions users have already encountered this behavior. |
Related to actions/runner-images#9644
`npm install -g bats` Above command was failing with below logs ``` With Unicode UTF-16 support. With native language support. With support to preserve the user and group ownership of files. LOCALEDIR: /usr/share/locale http://waterlan.home.xs4all.nl/dos2unix.html npm error code EACCES npm error syscall mkdir npm error path /usr/local/share/man/man7 npm error errno -13 npm error [Error: EACCES: permission denied, mkdir '/usr/local/share/man/man7'] { npm error errno: -13, npm error code: 'EACCES', npm error syscall: 'mkdir', npm error path: '/usr/local/share/man/man7' npm error } npm error npm error The operation was rejected by your operating system. npm error It is likely you do not have the permissions to access this file as the current user npm error npm error If you believe this might be a permissions issue, please double-check the npm error permissions of the file and its containing directories, or try running npm error the command again as root/Administrator. npm error A complete log of this run can be found in: /home/runner/.npm/_logs/2024-07-13T16_29_06_857Z-debug-0.log ``` References: 1. actions/runner-images#9644 2. https://github.com/microsoft/TypeScript/pull/58102/files 3. https://docs.npmjs.com/resolving-eacces-permissions-errors-when-installing-packages-globally
`npm install -g bats` Above command was failing with below logs ``` With Unicode UTF-16 support. With native language support. With support to preserve the user and group ownership of files. LOCALEDIR: /usr/share/locale http://waterlan.home.xs4all.nl/dos2unix.html npm error code EACCES npm error syscall mkdir npm error path /usr/local/share/man/man7 npm error errno -13 npm error [Error: EACCES: permission denied, mkdir '/usr/local/share/man/man7'] { npm error errno: -13, npm error code: 'EACCES', npm error syscall: 'mkdir', npm error path: '/usr/local/share/man/man7' npm error } npm error npm error The operation was rejected by your operating system. npm error It is likely you do not have the permissions to access this file as the current user npm error npm error If you believe this might be a permissions issue, please double-check the npm error permissions of the file and its containing directories, or try running npm error the command again as root/Administrator. npm error A complete log of this run can be found in: /home/runner/.npm/_logs/2024-07-13T16_29_06_857Z-debug-0.log ``` References: 1. actions/runner-images#9644 2. https://github.com/microsoft/TypeScript/pull/58102/files 3. https://docs.npmjs.com/resolving-eacces-permissions-errors-when-installing-packages-globally
- Prevent permission error when installing package globally - actions/runner-images#9644
- Prevent permission error when installing package globally - actions/runner-images#9644
Description
After
20240403.1.0
, global installs of specific versions of npm fail.20240324.2.0
does not fail.Platforms affected
Runner images affected
Image version and build link
20240403.1.0
https://github.com/jakebailey/hereby/actions/runs/8577653125/job/23510511696
Is it regression?
Yes, https://github.com/jakebailey/hereby/actions/runs/8563597643/job/23469083748
Expected behavior
npm install -g npm@<version>
should work.Actual behavior
npm install -g npm@<version>
fails with:Repro steps
Run
npm install -g [email protected]
. That's it.The text was updated successfully, but these errors were encountered: