Support for HTML email alerts/notifications
Either configurable or on by default, would be helpful in formatting and general visibility of the alert. As an example, when I want to include the stream URL via ${if stream_url}${stream_url}${end}, the URL will be exceptionally long in some cases. It'd be ideal to be able to format with tags
I looked around for some stuff on this and couldnt find anything (requests, posts on community board, etc)
HTML is not rendered because the email is sent with the following headers
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit
In https://github.com/Graylog2/graylog2-server/blob/master/graylog2-server/src/main/java/org/graylog2/alerts/FormattedEmailAlertSender.java line 171 you could use org.apache.commons.mail.HtmlEmail instead of SimpleEmail. Calling setHtmlMsg and then setTextMsg if users have configured HTML email and their clients dont support it (just an idea)
Although I am wiling to bet that this may cause issues with JMTE due to format and syntax requirements?
I would like to help with this.
But using the same template (with HTML tags) to send both HTML and text emails will generate unreadable emails to those clients not supporting HTML ( u know, with all the HTML tags as part of the body...).
Maybe separate both templates? Having one for text only and one for HTML? Or trying to remove html tags from the text template (not easy, though)
Does someone has a better approach?
Graylog 3.4 released and still no HTML e-mail support for alerts... Please add it.
re-reading the last comment from 2018 makes me think that if there was a user setting of "receive HTML emails" then HTML emails could be sent to those users who have it enabled and plaintext sent to those who dont
I'm also waiting for this change eagerly. It is not possible to build convenient e-mail alerting to business users basing on plain text messages. In recent times look counts a lot.
Graylog 4 RC here and HTML mail is still missing, please add it....
Most helpful comment
Graylog 3.4 released and still no HTML e-mail support for alerts... Please add it.