mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 16:09:32 +00:00
parent
4779f80fa8
commit
aca088ea13
14 changed files with 194 additions and 87 deletions
|
|
@ -19,6 +19,7 @@ local ifid = nil
|
|||
local available_modules = nil
|
||||
local interface_entity = alert_consts.alert_entities.interface.entity_id
|
||||
local iface_config = nil
|
||||
local confset_id = nil
|
||||
|
||||
-- The function below ia called once (#pragma once)
|
||||
function setup(str_granularity)
|
||||
|
|
@ -33,7 +34,7 @@ function setup(str_granularity)
|
|||
})
|
||||
|
||||
local configsets = user_scripts.getConfigsets()
|
||||
iface_config = user_scripts.getTargetConfig(configsets, "interface", ifname)
|
||||
iface_config, confset_id = user_scripts.getTargetConfig(configsets, "interface", ifname)
|
||||
end
|
||||
|
||||
-- #################################################################
|
||||
|
|
@ -74,7 +75,7 @@ function runScripts(granularity)
|
|||
|
||||
if(conf.enabled) then
|
||||
if((not user_script.is_alert) or (not suppressed_alerts)) then
|
||||
hook_fn({
|
||||
alerts_api.invokeScriptHook(user_script, confset_id, hook_fn, {
|
||||
granularity = granularity,
|
||||
alert_entity = entity_info,
|
||||
entity_info = info,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue