X-Git-Url: https://git.openstreetmap.org/chef.git/blobdiff_plain/d94299b4334d3bec30f7f06c873565cac267c595..5bac522a83a65e8a6c0b20e179ee794321ad4a99:/cookbooks/hardware/attributes/default.rb diff --git a/cookbooks/hardware/attributes/default.rb b/cookbooks/hardware/attributes/default.rb index 81416582d..ce7aae863 100644 --- a/cookbooks/hardware/attributes/default.rb +++ b/cookbooks/hardware/attributes/default.rb @@ -8,11 +8,11 @@ default[:hardware][:grub][:cmdline] = %w(nomodeset) default[:hardware][:sensors] = {} if node[:dmi] && node[:dmi][:system] - case dmi.system.manufacturer + case node[:dmi][:system][:manufacturer] when "HP" default[:apt][:sources] |= ["management-component-pack"] - case dmi.system.product_name + case node[:dmi][:system][:product_name] when "ProLiant DL360 G6", "ProLiant DL360 G7" default[:hardware][:sensors][:"power_meter-*"][:power][:power1] = { :ignore => true } end @@ -30,9 +30,7 @@ end if node[:kernel] && node[:kernel][:modules] raidmods = node[:kernel][:modules].keys & %w(cciss hpsa mptsas mpt2sas mpt3sas megaraid_mm megaraid_sas aacraid) - unless raidmods.empty? - default[:apt][:sources] |= ["hwraid"] - end + default[:apt][:sources] |= ["hwraid"] unless raidmods.empty? end if node[:kernel][:modules].include?("ipmi_si")