New email notification template (#11219)
* Add new mail template * use large enough initial buffers * pass the notification sender host to use in edit command part * formatting changes
Emmanuel Vasilakis committed
Jun 10, 2021 at 15:11 UTC
86c9ada59d5d7e1876d36aa1ffea13f1da90b10d
2 files changed
+802
-103
health/health.c
+37
-10
@@ -308,26 +308,44 @@ static inline void health_alarm_execute(RRDHOST *host, ALARM_ENTRY *ae) {
308
int n_warn=0, n_crit=0;
309
RRDCALC *rc;
310
EVAL_EXPRESSION *expr=NULL;
311
+ BUFFER *warn_alarms, *crit_alarms;
312
+
313
+ warn_alarms = buffer_create(NETDATA_WEB_RESPONSE_INITIAL_SIZE);
314
+ crit_alarms = buffer_create(NETDATA_WEB_RESPONSE_INITIAL_SIZE);
315
316
for(rc = host->alarms; rc ; rc = rc->next) {
317
if(unlikely(!rc->rrdset || !rc->rrdset->last_collected_time.tv_sec))
318
continue;
319
316
- if(unlikely(rc->status == RRDCALC_STATUS_WARNING)) {
317
- n_warn++;
318
- if (ae->alarm_id == rc->id)
319
- expr=rc->warning;
320
+ if (unlikely(rc->status == RRDCALC_STATUS_WARNING)) {
321
+ if (likely(ae->alarm_id != rc->id) || likely(ae->alarm_event_id != rc->next_event_id - 1)) {
322
+ if (n_warn)
323
+ buffer_strcat(warn_alarms, ",");
324
+ buffer_strcat(warn_alarms, rc->name);
325
+ buffer_strcat(warn_alarms, "=");
326
+ buffer_snprintf(warn_alarms, 11, "%ld", rc->last_status_change);
327
+ n_warn++;
328
+ } else if (ae->alarm_id == rc->id)
329
+ expr = rc->warning;
330
} else if (unlikely(rc->status == RRDCALC_STATUS_CRITICAL)) {
321
- n_crit++;
322
- if (ae->alarm_id == rc->id)
323
- expr=rc->critical;
331
+ if (likely(ae->alarm_id != rc->id) || likely(ae->alarm_event_id != rc->next_event_id - 1)) {
332
+ if (n_crit)
333
+ buffer_strcat(crit_alarms, ",");
334
+ buffer_strcat(crit_alarms, rc->name);
335
+ buffer_strcat(crit_alarms, "=");
336
+ buffer_snprintf(crit_alarms, 11, "%ld", rc->last_status_change);
337
+ n_crit++;
338
+ } else if (ae->alarm_id == rc->id)
339
+ expr = rc->critical;
340
} else if (unlikely(rc->status == RRDCALC_STATUS_CLEAR)) {
341
if (ae->alarm_id == rc->id)
326
- expr=rc->warning;
342
+ expr = rc->warning;
343
}
344
}
345
330
- snprintfz(command_to_run, ALARM_EXEC_COMMAND_LENGTH, "exec %s '%s' '%s' '%u' '%u' '%u' '%lu' '%s' '%s' '%s' '%s' '%s' '" CALCULATED_NUMBER_FORMAT_ZERO "' '" CALCULATED_NUMBER_FORMAT_ZERO "' '%s' '%u' '%u' '%s' '%s' '%s' '%s' '%s' '%s' '%d' '%d'",
346
+ char *edit_command = ae->source ? health_edit_command_from_source(ae->source) : strdupz("UNKNOWN=0");
347
+
348
+ snprintfz(command_to_run, ALARM_EXEC_COMMAND_LENGTH, "exec %s '%s' '%s' '%u' '%u' '%u' '%lu' '%s' '%s' '%s' '%s' '%s' '" CALCULATED_NUMBER_FORMAT_ZERO "' '" CALCULATED_NUMBER_FORMAT_ZERO "' '%s' '%u' '%u' '%s' '%s' '%s' '%s' '%s' '%s' '%d' '%d' '%s' '%s' '%s' '%s' '%s'",
349
exec,
350
recipient,
351
host->registry_hostname,
@@ -352,7 +370,12 @@ static inline void health_alarm_execute(RRDHOST *host, ALARM_ENTRY *ae) {
370
(expr && expr->source)?expr->source:"NOSOURCE",
371
(expr && expr->error_msg)?buffer_tostring(expr->error_msg):"NOERRMSG",
372
n_warn,
355
- n_crit
373
+ n_crit,
374
+ buffer_tostring(warn_alarms),
375
+ buffer_tostring(crit_alarms),
376
+ ae->classification?ae->classification:"Unknown",
377
+ edit_command,
378
+ localhost->registry_hostname
379
);
380
381
ae->flags |= HEALTH_ENTRY_FLAG_EXEC_RUN;
@@ -363,6 +386,10 @@ static inline void health_alarm_execute(RRDHOST *host, ALARM_ENTRY *ae) {
386
ae->exec_spawn_serial = spawn_enq_cmd(command_to_run);
387
enqueue_alarm_notify_in_progress(ae);
388
389
+ freez(edit_command);
390
+ buffer_free(warn_alarms);
391
+ buffer_free(crit_alarms);
392
+
393
return; //health_alarm_wait_for_execution
394
done:
395
health_alarm_log_save(host, ae);
health/notifications/alarm-notify.sh.in
+765
-93
@@ -239,6 +239,11 @@ else
239
calc_param_values="${22}" # the values of the parameters in the expression, at the time of the evaluation
240
total_warnings="${23}" # Total number of alarms in WARNING state
241
total_critical="${24}" # Total number of alarms in CRITICAL state
242
+ total_warn_alarms="${25}" # List of alarms in warning state
243
+ total_crit_alarms="${26}" # List of alarms in critical state
244
+ classification="${27}" # The class field from .conf files
245
+ edit_command_line="${28}" # The command to edit the alarm, with the line number
246
+ sender_host="${29}" # The host sending this notification
247
fi
248
249
# -----------------------------------------------------------------------------
@@ -252,6 +257,17 @@ else
257
host="${args_host}"
258
fi
259
260
+# -----------------------------------------------------------------------------
261
+# Do the same for sender_host (find a suitable hostname to use, if netdata did not supply a hostname)
262
+
263
+if [ -z ${sender_host} ]; then
264
+ this_host=$(hostname -s 2>/dev/null)
265
+ s_host="${this_host}"
266
+ sender_host="${this_host}"
267
+else
268
+ s_host="${sender_host}"
269
+fi
270
+
271
# -----------------------------------------------------------------------------
272
# screen statuses we don't need to send a notification
273
@@ -810,6 +826,14 @@ date=$(date --date=@${when} "${date_format}" 2>/dev/null)
826
[ -z "${date}" ] && date=$(date --date=@${when} 2>/dev/null)
827
[ -z "${date}" ] && date=$(date 2>/dev/null)
828
829
+# -----------------------------------------------------------------------------
830
+# get the date in utc the alarm happened
831
+
832
+date_utc=$(date --date=@${when} "${date_format}" -u 2>/dev/null)
833
+[ -z "${date_utc}" ] && date_utc=$(date -u "${date_format}" 2>/dev/null)
834
+[ -z "${date_utc}" ] && date_utc=$(date -u --date=@${when} 2>/dev/null)
835
+[ -z "${date_utc}" ] && date_utc=$(date -u 2>/dev/null)
836
+
837
# ----------------------------------------------------------------------------
838
# prepare some extra headers if we've been asked to thread e-mails
839
if [ "${SEND_EMAIL}" == "YES" ] && [ "${EMAIL_THREADING}" != "NO" ]; then
@@ -2266,8 +2290,10 @@ urlencode "${family}" >/dev/null
2290
url_family="${REPLY}"
2291
urlencode "${name}" >/dev/null
2292
url_name="${REPLY}"
2293
+urlencode "${value_string}" >/dev/null
2294
+url_value_string="${REPLY}"
2295
2270
-redirect_params="host=${url_host}&chart=${url_chart}&family=${url_family}&alarm=${url_name}&alarm_unique_id=${unique_id}&alarm_id=${alarm_id}&alarm_event_id=${event_id}&alarm_when=${when}"
2296
+redirect_params="host=${url_host}&chart=${url_chart}&family=${url_family}&alarm=${url_name}&alarm_unique_id=${unique_id}&alarm_id=${alarm_id}&alarm_event_id=${event_id}&alarm_when=${when}&alarm_status=${status}&alarm_chart=${chart}&alarm_value=${url_value_string}"
2297
GOTOCLOUD=0
2298
2299
if [ "${NETDATA_REGISTRY_URL}" == "https://registry.my-netdata.io" ]; then
@@ -2284,9 +2310,9 @@ fi
2310
if [ ${GOTOCLOUD} -eq 0 ]; then
2311
goto_url="${NETDATA_REGISTRY_URL}/goto-host-from-alarm.html?${redirect_params}"
2312
else
2287
- # Temporarily disable alarm redirection, as the cloud endpoint no longer exists. This functionality will be restored after discussion on #9487. For now, just lead to netdata.cloud
2288
- #goto_url="${NETDATA_REGISTRY_CLOUD_BASE_URL}/alarms/redirect?agentID=${NETDATA_REGISTRY_UNIQUE_ID}&${redirect_params}"
2289
- goto_url="${NETDATA_REGISTRY_CLOUD_BASE_URL}"
2313
+ # Temporarily disable alarm redirection, as the cloud endpoint no longer exists. This functionality will be restored after discussion on #9487. For now, just lead to netdata.cloud
2314
+ # Re-allow alarm redirection, for alarms 2.0, new template
2315
+ goto_url="${NETDATA_REGISTRY_CLOUD_BASE_URL}/alarms/redirect?agentId=${NETDATA_REGISTRY_UNIQUE_ID}&${redirect_params}"
2316
fi
2317
2318
# the severity of the alarm
@@ -2311,48 +2337,79 @@ alarm="${name//_/ } = ${value_string}"
2337
# the image of the alarm
2338
image="${images_base_url}/images/banner-icon-144x144.png"
2339
2340
+# have a default email status, in case the following case does not catch it
2341
+status_email_subject="${status}"
2342
+
2343
# prepare the title based on status
2344
case "${status}" in
2345
CRITICAL)
2346
image="${images_base_url}/images/alert-128-red.png"
2347
+ alarm_badge="${NETDATA_REGISTRY_CLOUD_BASE_URL}/static/email/img/label_critical.png"
2348
status_message="is critical"
2349
+ status_email_subject="Critical"
2350
color="#ca414b"
2351
+ rich_status_raised_for="Raised to critical, for ${non_clear_duration_txt}"
2352
+ background_color="#FFEBEF"
2353
+ border_color="#FF4136"
2354
+ text_color="#FF4136"
2355
+ action_text_color="#FFFFFF"
2356
;;
2357
2358
WARNING)
2359
image="${images_base_url}/images/alert-128-orange.png"
2360
+ alarm_badge="${NETDATA_REGISTRY_CLOUD_BASE_URL}/static/email/img/label_warning.png"
2361
status_message="needs attention"
2362
+ status_email_subject="Warning"
2363
color="#ffc107"
2364
+ rich_status_raised_for="Raised to warning, for ${non_clear_duration_txt}"
2365
+ background_color="#FFF8E1"
2366
+ border_color="#FFC300"
2367
+ text_color="#536775"
2368
+ action_text_color="#35414A"
2369
;;
2370
2371
CLEAR)
2372
image="${images_base_url}/images/check-mark-2-128-green.png"
2373
+ alarm_badge="${NETDATA_REGISTRY_CLOUD_BASE_URL}/static/email/img/label_recovered.png"
2374
status_message="recovered"
2375
+ status_email_subject="Clear"
2376
color="#77ca6d"
2377
+ rich_status_raised_for=
2378
+ background_color="#E5F5E8"
2379
+ border_color="#68C47D"
2380
+ text_color="#00AB44"
2381
+ action_text_color="#FFFFFF"
2382
;;
2383
esac
2384
2385
+# the html email subject
2386
+html_email_subject="${status_email_subject}, ${name} = ${value_string}, on ${host}"
2387
+
2388
if [ "${status}" = "CLEAR" ]; then
2389
severity="Recovered from ${old_status}"
2390
if [ ${non_clear_duration} -gt ${duration} ]; then
2391
raised_for="(alarm was raised for ${non_clear_duration_txt})"
2392
fi
2393
+ rich_status_raised_for="Recovered from ${old_status,,}, ${raised_for}"
2394
2395
# don't show the value when the status is CLEAR
2396
# for certain alarms, this value might not have any meaning
2397
alarm="${name//_/ } ${raised_for}"
2398
+ html_email_subject="${status_email_subject}, ${name} ${raised_for}, on ${host}"
2399
2400
elif { [ "${old_status}" = "WARNING" ] && [ "${status}" = "CRITICAL" ]; }; then
2401
severity="Escalated to ${status}"
2402
if [ ${non_clear_duration} -gt ${duration} ]; then
2403
raised_for="(alarm is raised for ${non_clear_duration_txt})"
2404
fi
2405
+ rich_status_raised_for="Escalated to critical, ${raised_for}"
2406
2407
elif { [ "${old_status}" = "CRITICAL" ] && [ "${status}" = "WARNING" ]; }; then
2408
severity="Demoted to ${status}"
2409
if [ ${non_clear_duration} -gt ${duration} ]; then
2410
raised_for="(alarm is raised for ${non_clear_duration_txt})"
2411
fi
2412
+ rich_status_raised_for="Demoted to warning, ${raised_for}"
2413
2414
else
2415
raised_for=
@@ -2638,117 +2695,732 @@ EOF
2695
2696
else
2697
2698
+now=$(date "+%s")
2699
+
2700
+if [ -n "$total_warn_alarms" ]; then
2701
+ while read -d, -r pair; do
2702
+ IFS='=' read -r key val <<<"$pair"
2703
+
2704
+ date_w=$(date --date=@${val} "${date_format}" 2>/dev/null)
2705
+ [ -z "${date_w}" ] && date_w=$(date "${date_format}" 2>/dev/null)
2706
+ [ -z "${date_w}" ] && date_w=$(date --date=@${val} 2>/dev/null)
2707
+ [ -z "${date_w}" ] && date_w=$(date 2>/dev/null)
2708
+
2709
+ elapsed=$((now - val))
2710
+
2711
+ duration4human ${elapsed} >/dev/null
2712
+ elapsed_txt="${REPLY}"
2713
+
2714
+ WARN_ALARMS+="
2715
+ <div class=\"set-font\" style=\"font-family: 'IBM Plex Sans', sans-serif; background: #FFFFFF; background-color: #FFFFFF; margin: 0px auto; max-width: 600px;\">
2716
+ <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"background:#FFFFFF;background-color:#FFFFFF;width:100%;\">
2717
+ <tbody>
2718
+ <tr>
2719
+ <td style=\"border-top:8px solid #F7F8F8;direction:ltr;font-size:0px;padding:20px 0;text-align:center;\">
2720
+ <!--[if mso | IE]><table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"><tr><td class=\"\" style=\"vertical-align:top;width:300px;\" ><![endif]-->
2721
+ <div class=\"mj-column-per-50 mj-outlook-group-fix\" style=\"font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:50%;\">
2722
+ <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"vertical-align:top;\" width=\"100%\">
2723
+ <tbody>
2724
+ <tr>
2725
+ <td align=\"left\" style=\"font-size:0px;padding:10px 25px;word-break:break-word;\">
2726
+ <div style=\"font-family:Open Sans, sans-serif;font-size:14px;font-weight:600;line-height:1;text-align:left;color:#35414A;\">${key}</div>
2727
+ </td>
2728
+ </tr>
2729
+ <tr>
2730
+ <td align=\"left\" style=\"font-size:0px;padding:10px 25px;padding-top:2px;word-break:break-word;\">
2731
+ <div style=\"font-family:Open Sans, sans-serif;font-size:12px;line-height:1;text-align:left;color:#35414A;\">${date_w}</div>
2732
+ </td>
2733
+ </tr>
2734
+ </tbody>
2735
+ </table>
2736
+ </div>
2737
+ <!--[if mso | IE]></td><td class=\"\" style=\"vertical-align:top;width:300px;\" ><![endif]-->
2738
+ <div class=\"mj-column-per-50 mj-outlook-group-fix\" style=\"font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:50%;\">
2739
+ <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">
2740
+ <tbody>
2741
+ <tr>
2742
+ <td style=\"vertical-align:top;padding-top:13px;\">
2743
+ <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style width=\"100%\">
2744
+ <tbody>
2745
+ <tr>
2746
+ <td align=\"right\" style=\"font-size:0px;padding:10px 25px;word-break:break-word;\">
2747
+ <div style=\"font-family:Open Sans, sans-serif;font-size:13px;line-height:1;text-align:right;color:#555555;\"><span style=\"background-color:#FFF8E1; border: 1px solid #FFC300; border-radius:36px; padding: 2px 12px; margin-top: 20px; white-space: nowrap\">
2748
+ Warning for ${elapsed_txt}
2749
+ </span></div>
2750
+ </td>
2751
+ </tr>
2752
+ </tbody>
2753
+ </table>
2754
+ </td>
2755
+ </tr>
2756
+ </tbody>
2757
+ </table>
2758
+ </div>
2759
+ <!--[if mso | IE]></td></tr></table><![endif]-->
2760
+ </td>
2761
+ </tr>
2762
+ </tbody>
2763
+ </table>
2764
+ </div>
2765
+ "
2766
+
2767
+ done <<<"$total_warn_alarms,"
2768
+fi
2769
+
2770
+if [ -n "$total_crit_alarms" ]; then
2771
+ while read -d, -r pair; do
2772
+ IFS='=' read -r key val <<<"$pair"
2773
+
2774
+ date_c=$(date --date=@${val} "${date_format}" 2>/dev/null)
2775
+ [ -z "${date_c}" ] && date_c=$(date "${date_format}" 2>/dev/null)
2776
+ [ -z "${date_c}" ] && date_c=$(date --date=@${val} 2>/dev/null)
2777
+ [ -z "${date_c}" ] && date_c=$(date 2>/dev/null)
2778
+
2779
+ elapsed=$((now - val))
2780
+
2781
+ duration4human ${elapsed} >/dev/null
2782
+ elapsed_txt="${REPLY}"
2783
+
2784
+ CRIT_ALARMS+="
2785
+ <div class=\"set-font\" style=\"font-family: 'IBM Plex Sans', sans-serif; background: #FFFFFF; background-color: #FFFFFF; margin: 0px auto; max-width: 600px;\">
2786
+ <table align=\"center\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"background:#FFFFFF;background-color:#FFFFFF;width:100%;\">
2787
+ <tbody>
2788
+ <tr>
2789
+ <td style=\"border-top:8px solid #F7F8F8;direction:ltr;font-size:0px;padding:20px 0;text-align:center;\">
2790
+ <!--[if mso | IE]><table role=\"presentation\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"><tr><td class=\"\" style=\"vertical-align:top;width:300px;\" ><![endif]-->
2791
+ <div class=\"mj-column-per-50 mj-outlook-group-fix\" style=\"font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:50%;\">
2792
+ <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style=\"vertical-align:top;\" width=\"100%\">
2793
+ <tbody>
2794
+ <tr>
2795
+ <td align=\"left\" style=\"font-size:0px;padding:10px 25px;word-break:break-word;\">
2796
+ <div style=\"font-family:Open Sans, sans-serif;font-size:14px;font-weight:600;line-height:1;text-align:left;color:#35414A;\">${key}</div>
2797
+ </td>
2798
+ </tr>
2799
+ <tr>
2800
+ <td align=\"left\" style=\"font-size:0px;padding:10px 25px;padding-top:2px;word-break:break-word;\">
2801
+ <div style=\"font-family:Open Sans, sans-serif;font-size:12px;line-height:1;text-align:left;color:#35414A;\">${date_c}</div>
2802
+ </td>
2803
+ </tr>
2804
+ </tbody>
2805
+ </table>
2806
+ </div>
2807
+ <!--[if mso | IE]></td><td class=\"\" style=\"vertical-align:top;width:300px;\" ><![endif]-->
2808
+ <div class=\"mj-column-per-50 mj-outlook-group-fix\" style=\"font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:50%;\">
2809
+ <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" width=\"100%\">
2810
+ <tbody>
2811
+ <tr>
2812
+ <td style=\"vertical-align:top;padding-top:13px;\">
2813
+ <table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" role=\"presentation\" style width=\"100%\">
2814
+ <tbody>
2815
+ <tr>
2816
+ <td align=\"right\" style=\"font-size:0px;padding:10px 25px;word-break:break-word;\">
2817
+ <div style=\"font-family:Open Sans, sans-serif;font-size:13px;line-height:1;text-align:right;color:#35414A;\"><span style=\"background-color:#FFEBEF; border: 1px solid #FF4136; border-radius:36px; padding: 2px 12px; margin-top: 20px; white-space: nowrap\">
2818
+ Critical for ${elapsed_txt}
2819
+ </span></div>
2820
+ </td>
2821
+ </tr>
2822
+ </tbody>
2823
+ </table>
2824
+ </td>
2825
+ </tr>
2826
+ </tbody>
2827
+ </table>
2828
+ </div>
2829
+ <!--[if mso | IE]></td></tr></table><![endif]-->
2830
+ </td>
2831
+ </tr>
2832
+ </tbody>
2833
+ </table>
2834
+ </div>
2835
+ "
2836
+
2837
+ done <<<"$total_crit_alarms,"
2838
+fi
2839
+
2840
+if [ -n "$edit_command_line" ]; then
2841
+ IFS='=' read -r edit_command line <<<"$edit_command_line"
2842
+fi
2843
+
2844
IFS='' read -r -d '' email_html_part <<EOF
2845
Content-Type: text/html; encoding=${EMAIL_CHARSET}
2846
Content-Disposition: inline
2847
Content-Transfer-Encoding: 8bit
2848
2646
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2647
-<html xmlns="http://www.w3.org/1999/xhtml" style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; box-sizing: border-box; font-size: 14px; margin: 0; padding: 0;">
2648
-<body style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; width: 100% !important; min-height: 100%; line-height: 1.6; background: #f6f6f6; margin:0; padding: 0;">
2649
-<table>
2650
- <tbody>
2651
- <tr>
2652
- <td style="vertical-align: top;" valign="top"></td>
2653
- <td width="700" style="vertical-align: top; display: block !important; max-width: 700px !important; clear: both !important; margin: 0 auto; padding: 0;" valign="top">
2654
- <div style="max-width: 700px; display: block; margin: 0 auto; padding: 20px;">
2655
- <table width="100%" cellpadding="0" cellspacing="0" style="background: #fff; border: 1px solid #e9e9e9;">
2849
+<!doctype html>
2850
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
2851
+<head>
2852
+ <title>
2853
+ </title>
2854
+ <!--[if !mso]><!-->
2855
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
2856
+ <!--<![endif]-->
2857
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
2858
+ <meta name="viewport" content="width=device-width, initial-scale=1">
2859
+ <style type="text/css">
2860
+ #outlook a { padding:0; }
2861
+ body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
2862
+ table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
2863
+ img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
2864
+ p { display:block;margin:13px 0; }
2865
+ </style>
2866
+ <!--[if mso]>
2867
+ <xml>
2868
+ <o:OfficeDocumentSettings>
2869
+ <o:AllowPNG/>
2870
+ <o:PixelsPerInch>96</o:PixelsPerInch>
2871
+ </o:OfficeDocumentSettings>
2872
+ </xml>
2873
+ <![endif]-->
2874
+ <!--[if lte mso 11]>
2875
+ <style type="text/css">
2876
+ .mj-outlook-group-fix { width:100% !important; }
2877
+ </style>
2878
+ <![endif]-->
2879
+ <!--[if !mso]><!-->
2880
+ <link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700&display=swap" rel="stylesheet" type="text/css">
2881
+ <link href="https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700" rel="stylesheet" type="text/css">
2882
+ <style type="text/css">
2883
+ @import url(https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700&display=swap);
2884
+ @import url(https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700);
2885
+ </style>
2886
+ <!--<![endif]-->
2887
+ <style type="text/css">
2888
+ @media only screen and (min-width:100px) {
2889
+ .mj-column-px-130 { width:130px !important; max-width: 130px; }
2890
+ .mj-column-per-50 { width:50% !important; max-width: 50%; }
2891
+ .mj-column-per-70 { width:70% !important; max-width: 70%; }
2892
+ .mj-column-per-30 { width:30% !important; max-width: 30%; }
2893
+ .mj-column-per-100 { width:100% !important; max-width: 100%; }
2894
+ .mj-column-px-66 { width:66px !important; max-width: 66px; }
2895
+ .mj-column-px-400 { width:400px !important; max-width: 400px; }
2896
+ }
2897
+ </style>
2898
+ <style type="text/css">
2899
+ @media only screen and (max-width:100px) {
2900
+ table.mj-full-width-mobile { width: 100% !important; }
2901
+ td.mj-full-width-mobile { width: auto !important; }
2902
+ }
2903
+ </style>
2904
+</head>
2905
+<body style="word-spacing:normal;">
2906
+<div class="svgbg" style="background-image: url('https://staging.netdata.cloud/static/email/img/isotype_600.png'); background-repeat: no-repeat; background-position: top center; background-size: 600px 192px;">
2907
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
2908
+ <div style="margin:0px auto;max-width:600px;">
2909
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
2910
+ <tbody>
2911
+ <tr>
2912
+ <td style="direction:ltr;font-size:0px;padding:20px 0;padding-bottom:50px;padding-left:0;text-align:left;">
2913
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:130px;" ><![endif]-->
2914
+ <div class="mj-column-px-130 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:130px;">
2915
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
2916
+ <tbody>
2917
+ <tr>
2918
+ <td align="center" style="font-size:0px;padding:10px 25px;padding-right:0;padding-left:0;word-break:break-word;">
2919
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;">
2920
<tbody>
2921
<tr>
2658
- <td bgcolor="#eee" style="padding: 5px 20px 5px 20px; background-color: #eee;">
2659
- <div style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 20px; color: #777; font-weight: bold;">netdata notification</div>
2660
- </td>
2922
+ <td style="width:130px;">
2923
+ <img alt="Netdata Logo" height="auto" src="https://app.netdata.cloud/static/email/img/full_logo.png" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:13px;" width="130">
2924
+ </td>
2925
</tr>
2926
+ </tbody>
2927
+ </table>
2928
+ </td>
2929
+ </tr>
2930
+ </tbody>
2931
+ </table>
2932
+ </div>
2933
+ <!--[if mso | IE]></td><td class="" style="vertical-align:top;width:300px;" ><![endif]-->
2934
+ <div class="mj-column-per-50 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:50%;">
2935
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" width="100%">
2936
+ <tbody>
2937
+ <tr>
2938
+ <td style="vertical-align:top;padding-top:4px;">
2939
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style width="100%">
2940
+ <tbody>
2941
<tr>
2663
- <td bgcolor="${color}" style="font-size: 16px; vertical-align: top; font-weight: 400; text-align: center; margin: 0; padding: 10px; color: #ffffff; background: ${color} !important; border: 1px solid ${color}; border-top-color: ${color};" align="center" valign="top">
2664
- <h1 style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-weight: 400; margin: 0;">${host} ${status_message}</h1>
2942
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-left:10px;word-break:break-word;">
2943
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;line-height:1;text-align:left;color:#35414A;">Notification</div>
2944
+ </td>
2945
+ </tr>
2946
+ </tbody>
2947
+ </table>
2948
+ </td>
2949
+ </tr>
2950
+ </tbody>
2951
+ </table>
2952
+ </div>
2953
+ <!--[if mso | IE]></td></tr></table><![endif]-->
2954
+ </td>
2955
+ </tr>
2956
+ </tbody>
2957
+ </table>
2958
+ </div>
2959
+ <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="no-collapse-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
2960
+ <div class="no-collapse" style="border-collapse: initial; margin: 0px auto; border-radius: 4px; max-width: 600px;">
2961
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;border-radius:4px;">
2962
+ <tbody>
2963
+ <tr>
2964
+ <td style="border:1px solid ${border_color};direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
2965
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="set-font-outlook" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:598px;" width="598" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
2966
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 598px;">
2967
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
2968
+ <tbody>
2969
+ <tr>
2970
+ <td style="direction:ltr;font-size:0px;padding:20px 0;padding-bottom:0;padding-top:0;text-align:center;">
2971
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:418.6px;" ><![endif]-->
2972
+ <div class="mj-column-per-70 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:70%;">
2973
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
2974
+ <tbody>
2975
+ <tr>
2976
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:15px;word-break:break-word;">
2977
+ <div style="font-family:Open Sans, sans-serif;font-size:20px;font-weight:700;line-height:1;text-align:left;color:#35414A;">${name}</div>
2978
+ </td>
2979
+ </tr>
2980
+ </tbody>
2981
+ </table>
2982
+ </div>
2983
+ <!--[if mso | IE]></td><td class="" style="vertical-align:top;width:179.4px;" ><![endif]-->
2984
+ <div class="mj-column-per-30 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:30%;">
2985
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
2986
+ <tbody>
2987
+ <tr>
2988
+ <td align="right" style="font-size:0px;padding:10px 25px;padding-right:25px;word-break:break-word;">
2989
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;">
2990
+ <tbody>
2991
+ <tr>
2992
+ <td style="width:100px;">
2993
+ <img height="auto" src="${alarm_badge}" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:13px;" width="100"/>
2994
+ </td>
2995
+ </tr>
2996
+ </tbody>
2997
+ </table>
2998
+ </td>
2999
+ </tr>
3000
+ </tbody>
3001
+ </table>
3002
+ </div>
3003
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3004
+ </td>
3005
+ </tr>
3006
+ </tbody>
3007
+ </table>
3008
+ </div>
3009
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="set-font-outlook" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:598px;" width="598" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3010
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 598px;">
3011
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3012
+ <tbody>
3013
+ <tr>
3014
+ <td style="direction:ltr;font-size:0px;padding:0;text-align:center;">
3015
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:598px;" ><![endif]-->
3016
+ <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
3017
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
3018
+ <tbody>
3019
+ <tr>
3020
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:0;word-break:break-word;">
3021
+ <div style="font-family:IBM Plex Sans, sans-serif;font-size:16px;line-height:1;text-align:left;color:#35414A;">on ${host}</div>
3022
</td>
3023
+ </tr>
3024
+ </tbody>
3025
+ </table>
3026
+ </div>
3027
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3028
+ </td>
3029
+ </tr>
3030
+ </tbody>
3031
+ </table>
3032
+ </div>
3033
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="set-font-outlook" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:598px;" width="598" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3034
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 598px;">
3035
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3036
+ <tbody>
3037
+ <tr>
3038
+ <td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
3039
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:598px;" ><![endif]-->
3040
+ <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
3041
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
3042
+ <tbody>
3043
+ <tr>
3044
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:0;word-break:break-word;">
3045
+ <div style="font-family:Open Sans, sans-serif;font-size:26px;font-weight:700;line-height:1;text-align:left;color:#35414A;"><span style="color: ${text_color}; font-size:26px; background: ${background_color}; padding:4px 24px; border-radius: 36px">${value_string}
3046
+ </span></div>
3047
+ </td>
3048
+ </tr>
3049
+ </tbody>
3050
+ </table>
3051
+ </div>
3052
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3053
+ </td>
3054
+ </tr>
3055
+ </tbody>
3056
+ </table>
3057
+ </div>
3058
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="set-font-outlook" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:598px;" width="598" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3059
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 598px;">
3060
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3061
+ <tbody>
3062
+ <tr>
3063
+ <td style="direction:ltr;font-size:0px;padding:20px 0;padding-bottom:0;padding-top:0;text-align:center;">
3064
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:598px;" ><![endif]-->
3065
+ <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
3066
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
3067
+ <tbody>
3068
+ <tr>
3069
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:0;word-break:break-word;">
3070
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;line-height:21px;text-align:left;color:#35414A;">Details: ${info}</div>
3071
+ </td>
3072
+ </tr>
3073
+ </tbody>
3074
+ </table>
3075
+ </div>
3076
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3077
+ </td>
3078
+ </tr>
3079
+ </tbody>
3080
+ </table>
3081
+ </div>
3082
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="set-font-outlook" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:598px;" width="598" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3083
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 598px;">
3084
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3085
+ <tbody>
3086
+ <tr>
3087
+ <td style="direction:ltr;font-size:0px;padding:20px 0;padding-bottom:0;padding-top:0;text-align:center;">
3088
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:598px;" ><![endif]-->
3089
+ <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
3090
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
3091
+ <tbody>
3092
+ <tr>
3093
+ <td align="center" vertical-align="middle" style="font-size:0px;padding:10px 25px;word-break:break-word;">
3094
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:separate;width:100%;line-height:100%;">
3095
+ <tr>
3096
+ <td
3097
+ align="center" bgcolor="${border_color}" role="presentation" style="border:none;border-radius:3px;cursor:auto;height:44px;background:${border_color};" valign="middle">
3098
+ <p style="display:block;background:${border_color};color:#ffffff;font-size:13px;font-weight:600;line-height:44px;margin:0;text-decoration:none;text-transform:none;mso-padding-alt:0px;border-radius:3px;">
3099
+ <a href="${goto_url}" style="color: ${action_text_color}; text-decoration: none; width: 100%; display: inline-block">GO TO CHART</a>
3100
+ </p>
3101
+ </td>
3102
+ </tr>
3103
+ </table>
3104
+ </td>
3105
+ </tr>
3106
+ </tbody>
3107
+ </table>
3108
+ </div>
3109
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3110
+ </td>
3111
+ </tr>
3112
+ </tbody>
3113
+ </table>
3114
+ </div>
3115
+ <!--[if mso | IE]></td></tr></table></td></tr></table><![endif]-->
3116
+ </td>
3117
+ </tr>
3118
+ </tbody>
3119
+ </table>
3120
+ </div>
3121
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3122
+ <div style="height:32px;line-height:32px;"> </div>
3123
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3124
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; background: ${background_color}; background-color: ${background_color}; margin: 0px auto; border-radius: 4px; max-width: 600px;">
3125
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:${background_color};background-color:${background_color};width:100%;border-radius:4px;">
3126
+ <tbody>
3127
+ <tr>
3128
+ <td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
3129
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
3130
+ <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
3131
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
3132
+ <tbody>
3133
+ <tr>
3134
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-bottom:6px;word-break:break-word;">
3135
+ <div style="font-family:Open Sans, sans-serif;font-size:18px;line-height:1;text-align:left;color:#35414A;">Chart:
3136
+ <span style="font-weight:700; font-size:20px">${chart}</span></div>
3137
+ </td>
3138
+ </tr>
3139
+ <tr>
3140
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:0;word-break:break-word;">
3141
+ <div style="font-family:Open Sans, sans-serif;font-size:18px;line-height:1;text-align:left;color:#35414A;">Family:
3142
+ <span style="font-weight:700; font-size:20px">${family}</span></div>
3143
+ </td>
3144
+ </tr>
3145
+ <tr>
3146
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:4px;word-break:break-word;">
3147
+ <div style="font-family:Open Sans, sans-serif;font-size:14px;line-height:1;text-align:left;color:#35414A;">${rich_status_raised_for}</div>
3148
+ </td>
3149
+ </tr>
3150
+ <tr>
3151
+ <td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
3152
+ <p style="border-top:solid 1px lightgrey;font-size:1px;margin:0px auto;width:100%;">
3153
+ </p>
3154
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:solid 1px lightgrey;font-size:1px;margin:0px auto;width:550px;" role="presentation" width="550px" ><tr><td style="height:0;line-height:0;">
3155
+ </td></tr></table><![endif]-->
3156
+ </td>
3157
+ </tr>
3158
+ <tr>
3159
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-bottom:6px;word-break:break-word;">
3160
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;line-height:1;text-align:left;color:#35414A;">On
3161
+ <span style="font-weight:600">${date}</span></div>
3162
+ </td>
3163
+ </tr>
3164
+ <tr>
3165
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:0;word-break:break-word;">
3166
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;line-height:1;text-align:left;color:#35414A;">By:
3167
+ <span style="font-weight:600">${host}</span></div>
3168
+ </td>
3169
+ </tr>
3170
+ <tr>
3171
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:4px;word-break:break-word;">
3172
+ <div style="font-family:Open Sans, sans-serif;font-size:14px;line-height:1;text-align:left;color:#35414A;">Global time:
3173
+ <span style="font-weight:600">${date_utc}</span></div>
3174
+ </td>
3175
+ </tr>
3176
+ <tr>
3177
+ <td align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;">
3178
+ <p style="border-top:solid 1px lightgrey;font-size:1px;margin:0px auto;width:100%;">
3179
+ </p>
3180
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:solid 1px lightgrey;font-size:1px;margin:0px auto;width:550px;" role="presentation" width="550px" ><tr><td style="height:0;line-height:0;">
3181
+ </td></tr></table><![endif]-->
3182
+ </td>
3183
+ </tr>
3184
+ <tr>
3185
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-bottom:6px;word-break:break-word;">
3186
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;line-height:1;text-align:left;color:#35414A;">Classification:
3187
+ <span style="font-weight:600">${classification}</span></div>
3188
+ </td>
3189
+ </tr>
3190
+ <tr>
3191
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:0;word-break:break-word;">
3192
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;line-height:1;text-align:left;color:#35414A;">Role:
3193
+ <span style="font-weight:600">${roles}</span></div>
3194
+ </td>
3195
+ </tr>
3196
+ </tbody>
3197
+ </table>
3198
+ </div>
3199
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3200
+ </td>
3201
+ </tr>
3202
+ </tbody>
3203
+ </table>
3204
+ </div>
3205
+ <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3206
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 600px;">
3207
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3208
+ <tbody>
3209
+ <tr>
3210
+ <td style="direction:ltr;font-size:0px;padding:20px 0;padding-left:25px;text-align:left;">
3211
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:66px;" ><![endif]-->
3212
+ <div class="mj-column-px-66 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:66px;">
3213
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" width="100%">
3214
+ <tbody>
3215
+ <tr>
3216
+ <td style="vertical-align:top;padding:0;">
3217
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style width="100%">
3218
+ <tbody>
3219
+ <tr>
3220
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-right:0;padding-left:0;word-break:break-word;">
3221
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;">
3222
+ <tbody>
3223
+ <tr>
3224
+ <td style="width:48px;">
3225
+ <img height="auto" src="https://app.netdata.cloud/static/email/img/community_icon.png" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:13px;" width="48">
3226
+ </td>
3227
+ </tr>
3228
+ </tbody>
3229
+ </table>
3230
+ </td>
3231
+ </tr>
3232
+ </tbody>
3233
+ </table>
3234
+ </td>
3235
+ </tr>
3236
+ </tbody>
3237
+ </table>
3238
+ </div>
3239
+ <!--[if mso | IE]></td><td align="left" class="" style="vertical-align:top;width:400px;" ><![endif]-->
3240
+ <div class="mj-column-px-400 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:400px;">
3241
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" width="100%">
3242
+ <tbody>
3243
+ <tr>
3244
+ <td style="vertical-align:top;padding-left:0;">
3245
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style width="100%">
3246
+ <tbody>
3247
+ <tr>
3248
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-left:0;word-break:break-word;">
3249
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;font-weight:700;line-height:1;text-align:left;color:#35414A;">Want to know more about this alert?</div>
3250
+ </td>
3251
+ </tr>
3252
+ <tr>
3253
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-left:0;word-break:break-word;">
3254
+ <div style="font-family:Open Sans, sans-serif;font-size:14px;line-height:1.3;text-align:left;color:#35414A;">Discuss and troubleshoot with others on the Netdata <a href="https://community.netdata.cloud/" class="link" style="color: #00AB44; text-decoration: none;">community forums</a></div>
3255
+ </td>
3256
</tr>
3257
+ </tbody>
3258
+ </table>
3259
+ </td>
3260
+ </tr>
3261
+ </tbody>
3262
+ </table>
3263
+ </div>
3264
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3265
+ </td>
3266
+ </tr>
3267
+ </tbody>
3268
+ </table>
3269
+ </div>
3270
+ <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3271
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 600px;">
3272
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3273
+ <tbody>
3274
+ <tr>
3275
+ <td style="direction:ltr;font-size:0px;padding:20px 0;padding-left:25px;text-align:left;">
3276
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:66px;" ><![endif]-->
3277
+ <div class="mj-column-px-66 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:66px;">
3278
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" width="100%">
3279
+ <tbody>
3280
+ <tr>
3281
+ <td style="vertical-align:top;padding:0;">
3282
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style width="100%">
3283
+ <tbody>
3284
<tr>
2668
- <td style="vertical-align: top;" valign="top">
2669
- <div style="margin: 0; padding: 20px; max-width: 700px;">
2670
- <table width="100%" cellpadding="0" cellspacing="0" style="max-width:700px">
2671
- <tbody>
2672
- <tr>
2673
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding:0 0 20px;" align="left" valign="top">
2674
- <span>${chart}</span>
2675
- <span style="display: block; color: #666666; font-size: 12px; font-weight: 300; line-height: 1; text-transform: uppercase;">Chart</span>
2676
- </td>
2677
- </tr>
2678
- <tr style="margin: 0; padding: 0;">
2679
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;" align="left" valign="top">
2680
- <span><b>${alarm}</b>${info_html}</span>
2681
- <span style="display: block; color: #666666; font-size: 12px; font-weight: 300; line-height: 1; text-transform: uppercase;">Alarm</span>
2682
- </td>
2683
- </tr>
2684
- <tr>
2685
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;" align="left" valign="top">
2686
- <span>${family}</span>
2687
- <span style="display: block; color: #666666; font-size: 12px; font-weight: 300; line-height: 1; text-transform: uppercase;">Family</span>
2688
- </td>
2689
- </tr>
2690
- <tr style="margin: 0; padding: 0;">
2691
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;" align="left" valign="top">
2692
- <span>${severity}</span>
2693
- <span style="display: block; color: #666666; font-size: 12px; font-weight: 300; line-height: 1; text-transform: uppercase;">Severity</span>
2694
- </td>
2695
- </tr>
2696
- <tr style="margin: 0; padding: 0;">
2697
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;" align="left" valign="top"><span>${date}</span>
2698
- <span>${raised_for_html}</span> <span style="display: block; color: #666666; font-size: 12px; font-weight: 300; line-height: 1; text-transform: uppercase;">Time</span>
2699
- </td>
2700
- </tr>
2701
- <tr style="margin: 0; padding: 0;">
2702
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;" align="left" valign="top">
2703
- <span>${calc_expression}</span>
2704
- <span style="display: block; color: #666666; font-size: 12px; font-weight: 300; line-height: 1; text-transform: uppercase;">Evaluated Expression</span>
2705
- </td>
2706
- </tr>
2707
- <tr style="margin: 0; padding: 0;">
2708
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;" align="left" valign="top">
2709
- <span>${calc_param_values}</span>
2710
- <span style="display: block; color: #666666; font-size: 12px; font-weight: 300; line-height: 1; text-transform: uppercase;">Expression Variables</span>
2711
- </td>
2712
- </tr>
2713
- <tr style="margin: 0; padding: 0;">
2714
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;" align="left" valign="top">
2715
- The host has ${total_warnings} WARNING and ${total_critical} CRITICAL alarm(s) raised.
2716
- </td>
2717
- </tr>
2718
-
2719
- <tr style="margin: 0; padding: 0;">
2720
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 18px; vertical-align: top; margin: 0; padding: 0 0 20px;">
2721
- <a href="${goto_url}" style="font-size: 14px; color: #ffffff; text-decoration: none; line-height: 1.5; font-weight: bold; text-align: center; display: inline-block; text-transform: capitalize; background: #35568d; border-width: 1px; border-style: solid; border-color: #2b4c86; margin: 0; padding: 10px 15px;" target="_blank">View Netdata</a>
2722
- </td>
2723
- </tr>
2724
- <tr style="text-align: center; margin: 0; padding: 0;">
2725
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 11px; vertical-align: top; margin: 0; padding: 10px 0 0 0; color: #666666;" align="center" valign="bottom">The source of this alarm is line <code>${src}</code><br/>(alarms are configurable, edit this file to adapt the alarm to your needs)
2726
- </td>
2727
- </tr>
2728
- <tr style="text-align: center; margin: 0; padding: 0;">
2729
- <td style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 12px; vertical-align: top; margin:0; padding: 20px 0 0 0; color: #666666; border-top: 1px solid #f0f0f0;" align="center" valign="bottom">Sent by
2730
- <a href="https://mynetdata.io/" target="_blank">netdata</a>, the real-time performance and health monitoring, on <code>${host}</code>.
2731
- </td>
2732
- </tr>
2733
- </tbody>
2734
- </table>
2735
- </div>
3285
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-right:0;padding-left:0;word-break:break-word;">
3286
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;">
3287
+ <tbody>
3288
+ <tr>
3289
+ <td style="width:48px;">
3290
+ <img height="auto" src="https://app.netdata.cloud/static/email/img/configure_icon.png" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:13px;" width="48">
3291
+ </td>
3292
+ </tr>
3293
+ </tbody>
3294
+ </table>
3295
+ </td>
3296
+ </tr>
3297
+ </tbody>
3298
+ </table>
3299
+ </td>
3300
+ </tr>
3301
+ </tbody>
3302
+ </table>
3303
+ </div>
3304
+ <!--[if mso | IE]></td><td align="left" class="" style="vertical-align:top;width:400px;" ><![endif]-->
3305
+ <div class="mj-column-px-400 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:400px;">
3306
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" width="100%">
3307
+ <tbody>
3308
+ <tr>
3309
+ <td style="vertical-align:top;padding-left:0;">
3310
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style width="100%">
3311
+ <tbody>
3312
+ <tr>
3313
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-left:0;word-break:break-word;">
3314
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;font-weight:700;line-height:1;text-align:left;color:#35414A;">Need to configure this alert?</div>
3315
+ </td>
3316
+ </tr>
3317
+ <tr>
3318
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-left:0;word-break:break-word;">
3319
+ <div style="font-family:Open Sans, sans-serif;font-size:14px;line-height:1.3;text-align:left;color:#35414A;"><span style="color: #00AB44"><a href="https://learn.netdata.cloud/docs/agent/health/notifications#:~:text=To%20edit%20it%20on%20your,have%20one%20or%20more%20destinations" class="link" style="color: #00AB44; text-decoration: none;">Edit</a></span> this alert's configuration file by logging into $s_host and running the following command:</div>
3320
+ </td>
3321
+ </tr>
3322
+ <tr>
3323
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:8px;padding-left:0;word-break:break-word;">
3324
+ <div style="font-family:Open Sans, sans-serif;font-size:12px;line-height:1.3;text-align:left;color:#35414A;">${edit_command} <br>
3325
+ The alarm to edit is at line {${line}}</div>
3326
+ </td>
3327
+ </tr>
3328
+ </tbody>
3329
+ </table>
3330
+ </td>
3331
+ </tr>
3332
+ </tbody>
3333
+ </table>
3334
+ </div>
3335
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3336
+ </td>
3337
+ </tr>
3338
+ </tbody>
3339
+ </table>
3340
+ </div>
3341
+ <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="history-wrapper-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3342
+ <div class="history-wrapper" style="background: #F7F8F8; background-color: #F7F8F8; margin: 0px auto; max-width: 100%;">
3343
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:#F7F8F8;background-color:#F7F8F8;width:100%;">
3344
+ <tbody>
3345
+ <tr>
3346
+ <td style="direction:ltr;font-size:0px;padding:0;padding-bottom:24px;text-align:center;">
3347
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="set-font-outlook" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3348
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 600px;">
3349
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3350
+ <tbody>
3351
+ <tr>
3352
+ <td style="direction:ltr;font-size:0px;padding:20px 0;padding-bottom:12px;text-align:center;">
3353
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
3354
+ <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
3355
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
3356
+ <tbody>
3357
+ <tr>
3358
+ <td align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;">
3359
+ <div style="font-family:Open Sans, sans-serif;font-size:16px;line-height:1;text-align:center;color:#35414A;">The node has
3360
+ <span style="font-weight:600">${total_warnings} warning</span>
3361
+ and
3362
+ <span style="font-weight:600">${total_critical} critical</span>
3363
+ additional active alert(s)</div>
3364
</td>
3365
+ </tr>
3366
+ </tbody>
3367
+ </table>
3368
+ </div>
3369
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3370
+ </td>
3371
+ </tr>
3372
+ </tbody>
3373
+ </table>
3374
+ </div>
3375
+ ${CRIT_ALARMS}
3376
+ ${WARN_ALARMS}
3377
+ <!--[if mso | IE]></td></tr></table></td></tr></table><![endif]-->
3378
+ </td>
3379
+ </tr>
3380
+ </tbody>
3381
+ </table>
3382
+ </div>
3383
+ <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="set-font-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
3384
+ <div class="set-font" style="font-family: 'IBM Plex Sans', sans-serif; margin: 0px auto; max-width: 600px;">
3385
+ <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
3386
+ <tbody>
3387
+ <tr>
3388
+ <td style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;">
3389
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
3390
+ <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
3391
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" width="100%">
3392
+ <tbody>
3393
+ <tr>
3394
+ <td style="vertical-align:top;padding-top:44px;padding-bottom:12px;">
3395
+ <table border="0" cellpadding="0" cellspacing="0" role="presentation" style width="100%">
3396
+ <tbody>
3397
+ <tr>
3398
+ <td align="left" style="font-size:0px;padding:10px 25px;padding-top:0;padding-bottom:0;word-break:break-word;">
3399
+ <div style="font-family:Open Sans, sans-serif;font-size:13px;line-height:1;text-align:center;color:#35414A;">© Netdata 2021 - The real-time performance and health monitoring</div>
3400
+ </td>
3401
</tr>
3402
</tbody>
2739
- </table>
2740
- </div>
3403
+ </table>
3404
+ </td>
3405
+ </tr>
3406
+ </tbody>
3407
+ </table>
3408
+ </div>
3409
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3410
</td>
2742
- </tr>
2743
- </tbody>
2744
-</table>
3411
+ </tr>
3412
+ </tbody>
3413
+ </table>
3414
+ </div>
3415
+ <!--[if mso | IE]></td></tr></table><![endif]-->
3416
+</div>
3417
</body>
3418
</html>
3419
EOF
3420
3421
send_email <<EOF
3422
To: ${to_email}
2751
-Subject: ${host} ${status_message} - ${name//_/ } - ${chart}
3423
+Subject: ${html_email_subject}
3424
MIME-Version: 1.0
3425
Content-Type: multipart/alternative; boundary="multipart-boundary"
3426
${email_thread_headers}