Sha256: 82d4e06141fab515cccef927f08649c08b9c74ca9f7fbfa03254177b4cf9df85

Contents?: true

Size: 367 Bytes

Versions: 51

Compression:

Stored size: 367 Bytes

Contents

require 'net/ping'

default[:host] = 'localhost'
default[:port] = 22
default[:timeout] = 5

collect do
  ::Net::Ping::TCP.econnrefused = true
  event(
      :service => "ping tcp #{plugin.host}:#{plugin.port}",
      :state => ::Net::Ping::TCP.new(plugin.host, plugin.port, plugin.timeout).ping,
      :description => "Ping tcp #{plugin.host}:#{plugin.port}"
  )
end

Version data entries

51 entries across 51 versions & 1 rubygems

Version Path
kurchatov-0.4.7 examples/ping_tcp.rb
kurchatov-0.4.6 examples/ping_tcp.rb
kurchatov-0.4.5 examples/ping_tcp.rb
kurchatov-0.4.4 examples/ping_tcp.rb
kurchatov-0.4.3 examples/ping_tcp.rb
kurchatov-0.4.2 examples/ping_tcp.rb
kurchatov-0.4.1 examples/ping_tcp.rb
kurchatov-0.3.8 examples/ping_tcp.rb
kurchatov-0.3.7 examples/ping_tcp.rb
kurchatov-0.3.6 examples/ping_tcp.rb
kurchatov-0.3.5 examples/ping_tcp.rb
kurchatov-0.3.4 examples/ping_tcp.rb
kurchatov-0.3.3 examples/ping_tcp.rb
kurchatov-0.3.2 examples/ping_tcp.rb
kurchatov-0.3.1 examples/ping_tcp.rb
kurchatov-0.3.0 examples/ping_tcp.rb
kurchatov-0.2.9 examples/ping_tcp.rb
kurchatov-0.2.8 examples/ping_tcp.rb
kurchatov-0.2.7 examples/ping_tcp.rb
kurchatov-0.2.6 examples/ping_tcp.rb