]> CyberLeo.Net >> Repos - CDN/status.git/blob - worker.rb
Add age to result view
[CDN/status.git] / worker.rb
1 $:.push('lib')
2 require 'checks'
3
4 $checks = Checks::Worker.new
5
6 pid = nil
7 while true
8   $checks.reload_config
9   Process.kill("TERM", pid) rescue nil if pid
10   pid = Process.fork do
11     $checks.check
12   end
13   Process.detach(pid)
14   sleep(60)
15 end