lib/heartcheck/checks/firewall.rb in heartcheck-1.0.3 vs lib/heartcheck/checks/firewall.rb in heartcheck-1.0.4
- old
+ new
@@ -17,10 +17,17 @@
end
private
def custom_error(service)
- @errors << "connection refused on: #{service.host}:#{service.port}"
+ error_message = "connection refused on: #{service.host}:#{service.port}"
+
+ if service.proxy
+ proxy_uri = URI(service.proxy)
+ error_message << " via proxy: #{proxy_uri.host}:#{proxy_uri.port}"
+ end
+
+ @errors << error_message
end
end
end
end