Package provider docs - upgrade clarification


#1

Hello!

Looking for some clarification on documentation of the package
resource @ http://wiki.opscode.com/display/chef/Resources#Resources-Package

Docs say “Upgrade a package - if version is provided, upgrade to that
specific version” but looking at the code in provider/package.rb I
can’t see a specific version being passed to upgrade_package, only the
candidate_version. Is this the correct behavior? Should an upgrade
with a specific version just call action_install?

This has caused confusion at least once here
http://tickets.opscode.com/browse/CHEF-1195

For now am I okay to change the docs to “Upgrade a package if a newer
version is available” ?


#2

On Mon, May 16, 2011 at 10:38 AM, Matthew Kent
mkent+chef-dev@magoazul.com wrote:

For now am I okay to change the docs to “Upgrade a package if a newer
version is available” ?

What feels right to me is:

Install - Make sure this package is installed. If it is not, install
the latest version
Install w/version - Make sure this version of this package is
installed. If it is not installed or is the wrong version, try to
install this version
Upgrade - Make sure that the latest version of this package is installed

Bryan