Sha256: eb6ab2ff2747d1cbfa0b0e45faeb923da6fb3c62ebd794e1969c5f6c8f454176
Contents?: true
Size: 478 Bytes
Versions: 11
Compression:
Stored size: 478 Bytes
Contents
:q module Serverspec module Type class Cgroup < Base attr_accessor :subsystem def method_missing(meth) if @subsystem.nil? @subsystem = meth.to_s self else param = "#{@subsystem}.#{meth.to_s}" ret = @runner.run_command("cgget -n -r #{param} #{@name} | awk '{print $2}'") val = ret.stdout.strip val = val.to_i if val.match(/^\d+$/) val end end end end end
Version data entries
11 entries across 11 versions & 1 rubygems