mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 07:59:35 +00:00
Refactors system stats in a module system_utils.lua
This commit is contained in:
parent
b194643a18
commit
ef06f9e1d3
5 changed files with 35 additions and 4 deletions
|
|
@ -10,6 +10,7 @@ local json = require ("dkjson")
|
|||
local page_utils = require("page_utils")
|
||||
local tracker = require("tracker")
|
||||
local storage_utils = require("storage_utils")
|
||||
local system_utils = require("system_utils")
|
||||
|
||||
if not isAllowedSystemInterface() then
|
||||
sendHTTPContentTypeHeader('text/html')
|
||||
|
|
@ -21,7 +22,7 @@ end
|
|||
|
||||
sendHTTPContentTypeHeader('application/json')
|
||||
|
||||
local stats = ntop.systemHostStat()
|
||||
local stats = system_utils.systemHostStats()
|
||||
stats.epoch = os.time()
|
||||
stats.storage = storage_utils.storageInfo()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue