Class: BlinkyMonitor::JenkinsServer

Inherits:
Object
  • Object
show all
Defined in:
lib/blinky_monitor/jenkins_server.rb

Instance Method Summary collapse

Constructor Details

#initialize(url) ⇒ JenkinsServer

Returns a new instance of JenkinsServer.



5
6
7
# File 'lib/blinky_monitor/jenkins_server.rb', line 5

def initialize url
  @url = url
end

Instance Method Details

#statusObject



9
10
11
# File 'lib/blinky_monitor/jenkins_server.rb', line 9

def status
  open("#{@url}/rssLatest").read.include?('(broken') ? :failure : :success
end