Implement alerts via email

Closes #272
This commit is contained in:
emanuele-f 2018-04-03 20:49:43 +02:00
parent 9889c291cc
commit 0f5d76ca74
14 changed files with 284 additions and 31 deletions

View file

@ -24,13 +24,7 @@ function slack.sendNotification(notif)
return false
end
local msg_prefix = ""
if notif.action == "engage" then
msg_prefix = "Alert Engaged: "
elseif notif.action == "release" then
msg_prefix = "Alert Released: "
end
local msg_prefix = alertNotificationActionToLabel(notif.action)
local message = {
channel = "#" .. notif.entity_type,