-
-
Notifications
You must be signed in to change notification settings - Fork 247
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
Issue with nodejs repo and npm package conflict #452
Comments
IMO it's best to avoid non-distribution package repos if possible. I use this module like this on Debian: class { 'nodejs':
manage_package_repo => false,
npm_package_ensure => present,
} |
Issue still exist and the reason is puppet itself. Found via debug run (CentOS 8 Stream system):
So the problem is that package also checks for Current workaround would be to use puppet-nodejs/manifests/install.pp Lines 47 to 52 in 30161b2
|
I'm pulling my hair out on issues with npm and nodejs on my Ubuntu 20.04.03 LTS machines..
If I run:
The nodesource repo will be added (which is fine), then the nodejs package will be installed (which is fine). The nodesource nodejs package provides npm. Perfect!
At this point, dpkg -l will show the nodejs package being installed, and the npm package isn't installed.
But, after this, puppet will remove the npm package, since the default setting for npm_package_ensure is absent. This somehow removes the nodejs package (not fine). No idea how this works, since according to apt the npm package isnt installed. But puppet says:
Notice: /Stage[main]/Nodejs::Install/Package[npm]/ensure: removed (corrective)
And /usr/bin/npm is gone, as is the nodejs package.
If I do:
Then that will fail. Nodejs will be installed from the nodesource repo, but the npm package only exists in the Ubuntu repo's, and that cannot be installed because it conflicts with the nodesource nodejs package.
So I'm in kind of a loop here!
Affected Puppet, Ruby, OS and module versions/distributions
The text was updated successfully, but these errors were encountered: