1
0
mirror of https://github.com/coreos/prometheus-operator.git synced 2026-02-05 06:45:27 +01:00

fix: support text-only email configs

Signed-off-by: Simon Pasquier <spasquie@redhat.com>
This commit is contained in:
Simon Pasquier
2023-08-10 17:54:45 +02:00
parent 2f756fa241
commit c72c87e434
6 changed files with 30 additions and 6 deletions

View File

@@ -1073,6 +1073,9 @@ func testAlertmanagerConfigCRD(t *testing.T) {
{Key: "Subject", Value: "subject"},
{Key: "Comment", Value: "comment"},
},
// HTML field with an empty string must appear as-is in the generated configuration.
// See https://github.com/prometheus-operator/prometheus-operator/issues/5421
HTML: pointer.String(""),
}},
VictorOpsConfigs: []monitoringv1alpha1.VictorOpsConfig{{
APIKey: &v1.SecretKeySelector{
@@ -1478,6 +1481,7 @@ receivers:
headers:
Comment: comment
Subject: subject
html: ""
pushover_configs:
- user_key: 1234abc
token: 1234abc