@cryptotaxi247 / netdata-1 / commits / 52429b0a2

Check configuration for CUSTOM and MSTEAM (#11113)

* check for DEFAULT_RECIPIENT_CUSTOM * also check for SEND_MSTEAM * unset SEND_MSTEAM during msteams migration

Emmanuel Vasilakis committed May 7, 2021 at 17:31 UTC 52429b0a254af2113e379d8a29a610b637e04111
1 file changed +4
health/notifications/alarm-notify.sh.in
+4
@@ -440,6 +440,7 @@ fi
440
441 msteams_migration() {
442 SEND_MSTEAMS=${SEND_MSTEAM:-$SEND_MSTEAMS}
443 + unset -v SEND_MSTEAM
444 DEFAULT_RECIPIENT_MSTEAMS=${DEFAULT_RECIPIENT_MSTEAM:-$DEFAULT_RECIPIENT_MSTEAMS}
445 MSTEAMS_WEBHOOK_URL=${MSTEAM_WEBHOOK_URL:-$MSTEAMS_WEBHOOK_URL}
446 MSTEAMS_ICON_DEFAULT=${MSTEAM_ICON_DEFAULT:-$MSTEAMS_ICON_DEFAULT}
@@ -596,6 +597,9 @@ filter_recipient_by_criticality() {
597 # check prowl
598 [ -z "${DEFAULT_RECIPIENT_PROWL}" ] && SEND_PROWL="NO"
599
600 +# check custom
601 +[ -z "${DEFAULT_RECIPIENT_CUSTOM}" ] && SEND_CUSTOM="NO"
602 +
603 if [ "${SEND_PUSHOVER}" = "YES" ] ||
604 [ "${SEND_SLACK}" = "YES" ] ||
605 [ "${SEND_ROCKETCHAT}" = "YES" ] ||