properly show raised for duration when status is CLEAR
Costa Tsaousis (ktsaou) committed
Oct 24, 2016 at 00:01 UTC
af426bf62ee1c1631b63c1927053c512b85be0bd
1 file changed
+4
-4
plugins.d/alarm-notify.sh
+4
-4
@@ -717,10 +717,6 @@ case "${status}" in
717
image="${images_base_url}/images/check-mark-2-128-green.png"
718
status_message="recovered"
719
color="#77ca6d"
720
-
721
- # don't show the value when the status is CLEAR
722
- # for certain alarms, this value might not have any meaning
723
- alarm="${name//_/ } ${raised_for}"
720
;;
721
esac
722
@@ -732,6 +728,10 @@ then
728
raised_for="(alarm was raised for ${non_clear_duration_txt})"
729
fi
730
731
+ # don't show the value when the status is CLEAR
732
+ # for certain alarms, this value might not have any meaning
733
+ alarm="${name//_/ } ${raised_for}"
734
+
735
elif [ "${old_status}" = "WARNING" -a "${status}" = "CRITICAL" ]
736
then
737
severity="Escalated to ${status}"