Last active
June 27, 2023 23:58
-
-
Save tyzbit/a1160351ffeb9421281759177e7bab80 to your computer and use it in GitHub Desktop.
OPNSense ntopng call webhook when in a Google Meet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- /usr/local/share/ntopng/scripts/callbacks/checks/hosts/custom_host_lua_script.lua | |
if (host.name() == "meet.google.com") then | |
local response, err = ntop.httpGet("https://home-assistant-url/api/webhook/webhook-url") | |
if err then | |
print("Webhook request for meet.google.com match failed: " .. err) | |
end | |
print("Active Google Meet in progress") | |
end | |
-- IMPORTANT: do not forget this return at the end of the script | |
return(0) | |
-- Recommend setting Remote Host Idle Timeout to 20 in Settings -> Cache Settings for ntoping so ntoping drops the host quicker |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment