We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc44127 commit 7259a99Copy full SHA for 7259a99
chef/lib/chef/provider/package/yum.rb
@@ -140,10 +140,11 @@ def install_package(name, version)
140
end
141
142
defupgrade_package(name,version)
143
-# If we have a version, we can upgrade - otherwise, install
144
-if@current_resource.version
+# If we're not given a version, running update is the correct
+# option. If we are, then running install_package is right.
145
+unlessversion
146
run_command_with_systems_locale(
-:command=>"yum -d0 -e0 -y update #{name}-#{version}"
147
+:command=>"yum -d0 -e0 -y update #{name}"
148
)
149
@yum.flush
150
else
0 commit comments