Sha256: e1203a86d53b66b3c7664138409b0050a68a1541696fca67e40d83d7a85a5a5a
Contents?: true
Size: 766 Bytes
Versions: 9
Compression:
Stored size: 766 Bytes
Contents
#!/usr/bin/env ruby require 'optimus-runner/server/optimus_runner_sm' require 'rufus/scheduler' require 'logger' require 'optimus-runner/utils/optimuscloudenv' optimus_runner_sm = OptimusRunnerSM.new scheduler = Rufus::Scheduler.new logger = Logger.new(STDOUT) logger.level = Logger::WARN logger.info "Starting Optimus runner..." puts ARGV OptimusCloudEnvLoader.new.loadEnv scheduler.interval '5s', :first_in => 0.1 do logger.info "Is Optimus runner idle? #{optimus_runner_sm.idle?}" optimus_runner_sm.create if optimus_runner_sm.idle? optimus_runner_sm.add if optimus_runner_sm.new_device_added? optimus_runner_sm.remove if optimus_runner_sm.device_removed? optimus_runner_sm.restart if optimus_runner_sm.session_terminated? end scheduler.join
Version data entries
9 entries across 9 versions & 1 rubygems