Skip to content
This repository has been archived by the owner on May 20, 2020. It is now read-only.

Commit

Permalink
Merge pull request #35 from Dictanova/force_package_confold
Browse files Browse the repository at this point in the history
Improve upgrade of deb package
  • Loading branch information
sunggun-yu committed Apr 5, 2016
2 parents 7d83e07 + 8b984dd commit 860f7b0
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions recipes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,18 @@
# Install MongoDB package
install_package = %w(mongodb-org-server mongodb-org-shell mongodb-org-tools)

case node['platform_family']
when 'debian'
# bypass dpkg errors about pre-existing init or conf file
packager_opts = '-o Dpkg::Options::="--force-confold" --force-yes'
else
packager_opts = ''
end

install_package.each do |pkg|
package pkg do
version node['mongodb3']['package']['version']
options packager_opts
action :install
end
end
Expand Down

0 comments on commit 860f7b0

Please sign in to comment.