Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include HTML (Content-Type: text/html) in email destination. #495

Open
adityaj1107 opened this issue Jun 2, 2021 · 7 comments
Open

Include HTML (Content-Type: text/html) in email destination. #495

adityaj1107 opened this issue Jun 2, 2021 · 7 comments
Assignees
Labels
backlog enhancement New feature or request

Comments

@adityaj1107
Copy link
Contributor

Issue by Sampathreddygopireddy118
Thursday Dec 10, 2020 at 14:42 GMT
Originally opened as opendistro-for-elasticsearch/alerting#324


Is your feature request related to a problem? Please describe.
currently email destination only supports (plain/text).

Describe the solution you'd like
It is really good to have the (Content-Type: text/html) in email destination.

Describe alternatives you've considered
Currently I using custom webhook destination for email notification.

@adityaj1107 adityaj1107 added backlog enhancement New feature or request labels Jun 2, 2021
@adityaj1107
Copy link
Contributor Author

Comment by anjanaasok
Monday Mar 08, 2021 at 09:36 GMT


@Sampathreddygopireddy118 can you share the custom webhook that you created, How did you pass the context over to webhoook. DO we pass the ctx object in the URL of webhook

@adityaj1107
Copy link
Contributor Author

Comment by Sampathreddygopireddy118
Tuesday Mar 09, 2021 at 15:45 GMT


I was able to do the HTML format for email using custom webhook (destination as jenkins (generic-webhook-trigger)). Below are the steps if someone wants to do it.
Steps:

Message info in opendistro alerting write your message including painless script and include html tags.
create a free-style jenkins job -> enable the generic webhook trigger-> provide the variable to receive text format from kibana (custom webhook).
enable/create execute shell in Build, and write the incoming text (variable assigned in generic webhook) to a file with html extention (echo $variable > email.html).
enable editable email notification in your post build. Follow the steps from the document below.
https://dzone.com/articles/jenkins-convert-excel-data-to-tabular-format-and-s
Hope this helps. Let me know if you need any other details. My email: [email protected]

@brijos
Copy link

brijos commented Apr 5, 2022

Closing as solved.

@brijos brijos closed this as completed Apr 5, 2022
@brijos
Copy link

brijos commented Apr 5, 2022

Closing as solved.

@brijos brijos reopened this Jul 19, 2022
@brijos brijos transferred this issue from opensearch-project/alerting Aug 2, 2022
@qmonitoring
Copy link

@brijos, could you please clarify if native HTML support has been added?

@brijos
Copy link

brijos commented Aug 25, 2022

Thanks @qmonitoring. It was not fixed as asked so I reopened it. There is a workaround as Sampath calls out though.

@xluo-aws
Copy link
Member

There is another issue #586 that we are working on right now.

@xluo-aws xluo-aws assigned gaobinlong and unassigned qreshi Jun 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

6 participants