]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/hardware/recipes/default.rb
Fix rubocop warning
[chef.git] / cookbooks / hardware / recipes / default.rb
index 1a9549d7cd663bcaacbe4f09a74169038df5ca83..f2af6c9863af0365a1ec0081777f1c670da4ba7c 100644 (file)
@@ -65,6 +65,18 @@ when "HP"
     supports :status => true, :restart => true
   end
 
+  if product.end_with?("Gen8", "Gen9")
+    package "hp-ams" do
+      action :install
+      notifies :restart, "service[hp-ams]"
+    end
+
+    service "hp-ams" do
+      action [:enable, :start]
+      supports :status => true, :restart => true
+    end
+  end
+
   units << "1"
 when "TYAN"
   units << "0"
@@ -81,21 +93,6 @@ when "IBM"
   units << "0"
 end
 
-# Remove legacy HP G4 support which breaks modern hp-health 10.4
-if manufacturer == "HP"
-  %w[/opt/hp/hp-health/bin/hpasmd /usr/lib/libhpasmintrfc.so.3.0 /usr/lib/libhpasmintrfc.so.3 /usr/lib/libhpasmintrfc.so].each do |filename|
-    file filename do
-      action :delete
-      manage_symlink_source false
-    end
-  end
-
-  directory "/opt/hp/hp-legacy" do
-    action :delete
-    recursive true
-  end
-end
-
 units.sort.uniq.each do |unit|
   if node[:lsb][:release].to_f >= 16.04
     service "serial-getty@ttyS#{unit}" do