Skip to content
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

Unable to upgrade module when using "puppet module upgrade" #316

Closed
luisosses opened this issue Jun 2, 2015 · 9 comments
Closed

Unable to upgrade module when using "puppet module upgrade" #316

luisosses opened this issue Jun 2, 2015 · 9 comments

Comments

@luisosses
Copy link

If for some reason someone has the latest version of puppetlabs-apt installed, then the dependencies of the latest version of this module cannot be installed at the moment.

Seems that on the updated metadata.json the version related to the puppetlabs-apt module will need to be updated to at least the actual version 2.0.1.

Is there any reason that the version 2.0.1 of puppetlabs-apt may not fit the requirements or affect the actual deployment of version 1.4.0?

My actual use case is that I'm installing a new orchestration system that is being managed from Puppet and I cannot use the latest version of this module.

@luisosses
Copy link
Author

PR #317 created just in case.

@rtyler
Copy link

rtyler commented Jun 2, 2015

Do you have a stacktrace or error for this? I'm not sure I entirely understand why this is causing problems

@luisosses
Copy link
Author

Initially this is the error that I'm receiving:

puppet module upgrade rtyler-jenkins --modulepath modules
Notice: Preparing to upgrade 'rtyler-jenkins' ...
Notice: Found 'rtyler-jenkins' (v1.3.0) in /.../modules ...
Notice: Downloading from https://forgeapi.puppetlabs.com ...
Error: Could not upgrade module 'rtyler-jenkins' (v1.3.0 -> latest)
  There are 1 newer versions
    No combination of dependency upgrades would satisfy all dependencies
    Dependencies will not be automatically upgraded across major versions
    Upgrading one or more of these modules may permit the upgrade to succeed:
    - puppetlabs-stdlib
    - puppetlabs-apt
    - puppetlabs-java
    - darin-zypprepo
    - nanliu-staging
    Use `puppet module upgrade --force` to upgrade only this module

This issue happens because I've installed the module puppetlabs-apt before rtyler-jenkins so the system is installing the latest version at this moment of puppetlabs-apt (v2.0.1) and then doesn't permit to upgrade the actual version of rtyler-jenkins (v1.3.0)

The others modules are still within the dependencies version range, the only one that doesn't fit the actual version is the dependency for puppetlabs-apt.

@luisosses
Copy link
Author

@rtyler I've implemented my configuration using librarian-puppet to control the dependencies better in our installation. Based on this, the version installed of puppetlabs-apt will be v1.8.0.

In that way there's no problem to use the module.

In other hand if you give me the green light I would like to propose the code for using the latest version of puppetlabs-apt as it seems a bit more reliable on handling the keys/sources from packages.

@madAndroid
Copy link
Contributor

We're also experiencing this issue; the symptoms are slightly different - when we've got other modules in the Puppetfile which reference 'puppetlabs-apt', '>= 2.0.0', the dependency resolution fails, and the installation fails. Is there any specific reason puppetlabs-apt is being pinned to 1.8.0?

@luisosses
Copy link
Author

@madAndroid I've verified the code and the initial issue is related to how the rtyler-jenkins module uses APT to install the packages. Since version 2.0.0 of puppetlabs-apt, some of the ways to declare the sources changed, therefore if you want to install version 1.4.0 of this module, then you will need to install puppetlabs-apt version 1.8.0.

In my previous comment I've asked @rtyler if it's ok to propose the adaptation of the necessary classes in order to be able to use puppetlabs-apt >= 2.0.0, but so far didn't received an answer and didn't wanted to come with proposed code and being invasive on the development of this module.

@madAndroid
Copy link
Contributor

There are existing PRs for this at #281 and #301, which address the changes required for supporting puppetlabs-apt > 2.0.x - perhaps these PRs can be consolidated to address the issue ( cc @jhoblitt )

@luisosses
Copy link
Author

@madAndroid I've checked @jhoblitt PR and seems a very good change. Additionally to this I saw the comment in the conversation about the upgrade of puppetlabs-apt but just in case wanted to collaborate and updated PR #317 with also a bit of refactor in order to not to repeat Keys and URL's in the conditions. (cc @tedivm to be aware)

@luisosses
Copy link
Author

Puppetlabs-apt Module was updated to be backward compatible for declaration of Sources .

Closing this one as is not relevant anymore (Unless someone wants to change the format to the version 2.x)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants