]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/hardware/recipes/default.rb
Disable download of Intel MAS tool until Intel sort their shit out
[chef.git] / cookbooks / hardware / recipes / default.rb
index 04aef48a8d7c15e7ff2b7a974a8fcf42043dd8c1..50e98a60667c8caa7c42311106b1d8e33148f09a 100644 (file)
@@ -17,7 +17,6 @@
 # limitations under the License.
 #
 
-include_recipe "apt"
 include_recipe "git"
 include_recipe "munin"
 include_recipe "prometheus"
@@ -57,6 +56,8 @@ end
 
 case manufacturer
 when "HP"
+  include_recipe "apt::management-component-pack"
+
   package "hponcfg"
 
   execute "update-ilo" do
@@ -225,6 +226,19 @@ ohai_plugin "lldp" do
   template "lldp.rb.erb"
 end
 
+package %w[
+  rasdaemon
+  ruby-sqlite3
+]
+
+service "rasdaemon" do
+  action [:enable, :start]
+end
+
+prometheus_exporter "rasdaemon" do
+  port 9797
+end
+
 tools_packages = []
 status_packages = {}
 
@@ -299,6 +313,8 @@ else
   end
 end
 
+include_recipe "apt::hwraid" unless status_packages.empty?
+
 if status_packages.include?("cciss-vol-status")
   template "/usr/local/bin/cciss-vol-statusd" do
     source "cciss-vol-statusd.erb"
@@ -382,9 +398,9 @@ if !intel_ssds.empty? || !intel_nvmes.empty?
   intel_mas_tool_version = "1.10"
   intel_mas_package_version = "#{intel_mas_tool_version}.155-0"
 
-  remote_file "#{Chef::Config[:file_cache_path]}/Intel_MAS_CLI_Tool_#{intel_mas_tool_version}_Linux.zip" do
-    source "https://downloadmirror.intel.com/646992/Intel_MAS_CLI_Tool_Linux_#{intel_mas_tool_version}-v2.zip"
-  end
+  remote_file "#{Chef::Config[:file_cache_path]}/Intel_MAS_CLI_Tool_#{intel_mas_tool_version}_Linux.zip" do
+    source "https://downloadmirror.intel.com/646992/Intel_MAS_CLI_Tool_Linux_#{intel_mas_tool_version}-v2.zip"
+  end
 
   execute "#{Chef::Config[:file_cache_path]}/Intel_MAS_CLI_Tool_#{intel_mas_tool_version}_Linux.zip" do
     command "unzip Intel_MAS_CLI_Tool_#{intel_mas_tool_version}_Linux.zip intelmas_#{intel_mas_package_version}_amd64.deb"
@@ -398,10 +414,6 @@ if !intel_ssds.empty? || !intel_nvmes.empty?
     version "#{intel_mas_package_version}"
     source "#{Chef::Config[:file_cache_path]}/intelmas_#{intel_mas_package_version}_amd64.deb"
   end
-
-  dpkg_package "isdct" do
-    action :purge
-  end
 end
 
 disks = disks.map do |disk|