Crowdsec been great i but container restart when configuring notifications

No emails at all - but thats a different issues I guess now…

Hmm check the crowdsec logs that it has loaded the plugin, you can also test the plugin via

cscli notifications test <plugin_name>

Sorry - I was asleep again - Jeez - You know all the tricks - That would have been helpful in the email setup online guide. I ran it - and got this -

INFO registered plugin email_default
INFO pluginTomb dying
ERRO rpc error: code = Unknown desc = Mail Error on dialing with encryption type SSL/TLS: tls: first record does not look like a TLS handshake error, retry num 1 plugin=email_default
ERRO rpc error: code = Unknown desc = Mail Error on dialing with encryption type SSL/TLS: tls: first record does not look like a TLS handshake plugin:=email_default
INFO killing all plugins
DEBU[0002] received EOF, stopping recv loop err=“rpc error: code = Unavailable desc = error reading from server: EOF”
INFO[0002] plugin process exited path=/usr/local/lib/crowdsec/plugins/notification-email pid=575
DEBU[0002] plugin exited

My file looks like this - all the usual email stuff I have used in the past for many other systems. I cant paste it as I am a ‘new user’ here and cant have more than 2 links in a post - I removed the emails, but I dont know what this system is referring too…

I googled the error and found this in another post which I copied below - and this is still correct. I changed to starttls (which was not one of the options in the file) for the port 587 - and now I get a test email with you plugin test - I look forward to the real thing now later… Thanks heaps again for your assistance here.

------ post below copied - not mine ---------

I got it working on my end. Looks like you can do either:

smtp_port:       465
encryption_type: ssltls

Or:

smtp_port:       587
encryption_type: starttls

But not other combinations of port/encryption.

The Gmail SMTP docs say 465 is for “SSL” and 587 for “TLS/STARTTLS”.

I think the CrowdSec gmail example has a mistake, and my email.yaml template doesn’t list “starttls” as a value. I reported these issues on github (#2067 ).