I've been experimenting with elastic watcher over the past few days and have been pretty impressed with the alerting API so far. One thing I have had trouble with is configuring email action. We have a passwordless SMTP server "testpool.companydev.com" that I am having trouble configuring.
Receiving the following exception when I attempt to send an email:
MailConnectException[Couldn't connect to host, port: testpool.companydev.com, 587; timeout 120000]; nested: ConnectException[Connection refused]
I don't believe there is a firewall issue on our end, which is something I am looking into right now. But I do want to confirm that there are no red flags in our configuration..
elasticsearch.yml,
watcher.actions.email.service.account:
work:
email_defaults:
from: alerts@testcompanydev.com
smtp:
auth: false
starttls.enable: true
host: testpool.companydev.com
port: 587
watch settings,
{
"trigger" : {
"schedule" : { "interval" : "10m" }
},
"input" : {
"search" : {
"request" : {
"indices" : [ "logstash-*" ],
"body" : {
"query" : {
"bool" : {
"must" : {
"match" : { "message": "failure" }
},
"filter" : {
"range": {
"@timestamp" : {
"from": "now-1h",
"to": "now"
}
}
}
}
}
}
}
}
},
"actions" : {
"ses_account" : {
"email" : {
"from": "alerts@testcompanydev.com",
"to": "<destination_email>",
"subject": "Test Fail Alert",
"body": "This is a test alert."
}
}
}
}
Thank you,
Ravi