Sha256: 78e6686ed69d5a4ca5b126ebf0c5abc0ee59f9db30c8172af7be4dab5b47ee02
Contents?: true
Size: 351 Bytes
Versions: 53
Compression:
Stored size: 351 Bytes
Contents
module Bluepill module ProcessConditions class CpuUsage < ProcessCondition def initialize(options = {}) @below = options[:below] end def run(pid) # third col in the ps axu output System.cpu_usage(pid).to_f end def check(value) value < @below end end end end
Version data entries
53 entries across 53 versions & 8 rubygems