[library] package resource munge - override "latest" as well

Bug #1348658 reported by Aleksandr Didenko
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Committed
High
Dmitry Ilyin
5.0.x
Invalid
High
Dmitry Ilyin

Bug Description

We need to make sure we override (munge) "ensure => latest" just like we do for "ensure => present" in package resource.

In case we have a specific version requirement for the package, we'll install that version instead of "latest" - that's the behavior we expect during OpenStack patching. In other cases puppet will install "latest" available package.

We need to do this because some manifests may use "latest" instead of "present/installed" in their packages declaration and unexpected package upgrade during OpenStack patching (updating or downgrading packages) could cause huge problems. So it would be much safer and more convenient to override "ensure => latest" in "package" puppet resource than checking all manifests and replacing "latest" with "present".

Tags: library
Changed in fuel:
milestone: none → 5.1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-library (master)

Fix proposed to branch: master
Review: https://review.openstack.org/110316

Changed in fuel:
status: Confirmed → In Progress
Revision history for this message
Dmitry Ilyin (idv1985) wrote :

All manifests in fuel 5.0.X were cleared from 'latest' packages and there are only 'installed' packages so this fix is not needed. In 5.1 we have taken manu manifests from upstream and there are some 'latest' packages again. We don't want to modify upstream packages so we need to override 'latests' to the vesion taken from version files as well as for 'installed' packeges. Without it rollback will not work because Puppet will try to installe lates package even if told to return to a previous one.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-library (master)

Reviewed: https://review.openstack.org/110316
Committed: https://git.openstack.org/cgit/stackforge/fuel-library/commit/?id=ba569a48f449da8df7afed9473b6a875457f4270
Submitter: Jenkins
Branch: master

commit ba569a48f449da8df7afed9473b6a875457f4270
Author: Dmitry Ilyin <email address hidden>
Date: Tue Jul 29 19:01:27 2014 +0400

    Lookup versions for :latest as well as :installed

    If there is a package vesion in version files take it
    instead of the latest version from repository not only for
    :present and :installed packages but for :latest too.

    There was no :latest packages in out manifests before
    but now we have some again and without his fix rollback will
    not work for these packages.

    Change-Id: Ifd14d644d1da4172e92562d693f74d2f542982dd
    Closes-Bug: 1348658

Changed in fuel:
status: In Progress → Fix Committed
Dmitry Pyzhov (dpyzhov)
no longer affects: fuel/5.1.x
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.