tcpconns.lua 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. -- Copyright 2008 Freifunk Leipzig / Jo-Philipp Wich <jow@openwrt.org>
  2. -- Licensed to the public under the Apache License 2.0.
  3. m = Map("luci_statistics",
  4. translate("TCPConns Plugin Configuration"),
  5. translate(
  6. "The tcpconns plugin collects informations about open tcp " ..
  7. "connections on selected ports."
  8. ))
  9. -- collectd_tcpconns config section
  10. s = m:section( NamedSection, "collectd_tcpconns", "luci_statistics" )
  11. -- collectd_tcpconns.enable
  12. enable = s:option( Flag, "enable", translate("Enable this plugin") )
  13. enable.default = 0
  14. -- collectd_tcpconns.listeningports (ListeningPorts)
  15. listeningports = s:option( Flag, "ListeningPorts", translate("Monitor all local listen ports") )
  16. listeningports.default = 1
  17. listeningports:depends( "enable", 1 )
  18. -- collectd_tcpconns.localports (LocalPort)
  19. localports = s:option( Value, "LocalPorts", translate("Monitor local ports") )
  20. localports.optional = true
  21. localports:depends( "enable", 1 )
  22. -- collectd_tcpconns.remoteports (RemotePort)
  23. remoteports = s:option( Value, "RemotePorts", translate("Monitor remote ports") )
  24. remoteports.optional = true
  25. remoteports:depends( "enable", 1 )
  26. return m