summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith84@gmail.com>2020-10-31 17:46:20 -0700
committerTim Smith <tsmith84@gmail.com>2020-10-31 17:46:20 -0700
commit459a00a33394ae8127d899e924b83de5fef85a83 (patch)
tree498b6c7a688ca4b94029b8980a3272c91abde170
parentdf9a9efc901162a3db6ee1dd787ccbd53eabdf77 (diff)
downloadohai-memory.tar.gz
Check for the Rackspace kernel 3x fastermemory
Also avoid creating an array while we do it Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--lib/ohai/plugins/rackspace.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ohai/plugins/rackspace.rb b/lib/ohai/plugins/rackspace.rb
index 83603f86..02b06d1a 100644
--- a/lib/ohai/plugins/rackspace.rb
+++ b/lib/ohai/plugins/rackspace.rb
@@ -26,7 +26,7 @@ Ohai.plugin(:Rackspace) do
# true:: If kernel name matches
# false:: Otherwise
def has_rackspace_kernel?
- kernel[:release].split("-").last.eql?("rscloud")
+ kernel[:release].end_with?("-rscloud")
end
# Checks for rackspace provider attribute