From 0aa0ace9bcca80af45e1060d2bfb730d3ef95836 Mon Sep 17 00:00:00 2001
From: Josh Frye <joshfng@gmail.com>
Date: Thu, 23 Jun 2016 10:56:41 -0400
Subject: [PATCH] Change load average to cpu/cores on system info.

---
 app/controllers/admin/system_info_controller.rb | 3 ++-
 app/views/admin/system_info/show.html.haml      | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/app/controllers/admin/system_info_controller.rb b/app/controllers/admin/system_info_controller.rb
index b7333139c57..3c67370b667 100644
--- a/app/controllers/admin/system_info_controller.rb
+++ b/app/controllers/admin/system_info_controller.rb
@@ -1,7 +1,8 @@
 class Admin::SystemInfoController < Admin::ApplicationController
   def show
     system_info = Vmstat.snapshot
-    @load = system_info.load_average.collect { |v| v.round(2) }.join(', ')
+
+    @cpus = system_info.cpus.length
 
     @mem_used = system_info.memory.active_bytes
     @mem_total = system_info.memory.total_bytes
diff --git a/app/views/admin/system_info/show.html.haml b/app/views/admin/system_info/show.html.haml
index 542498cfb22..3ef2f20b589 100644
--- a/app/views/admin/system_info/show.html.haml
+++ b/app/views/admin/system_info/show.html.haml
@@ -7,9 +7,9 @@
   .row
     .col-sm-4
       .light-well
-        %h4 CPU Load
+        %h4 CPU
         .data
-          %h1= @load
+          %h1= "#{@cpus} cores"
     .col-sm-4
       .light-well
         %h4 Memory
-- 
GitLab