mirror of
https://github.com/prometheus/alertmanager
synced 2024-12-26 16:12:20 +00:00
2f055d9966
When users start Alertmanager with `--cluster.listen-address=`, the cluster will not be initialized, hence api.peer will be `nil`. So far this would result in a nil pointer dereference by the API v2 accessing the api.peer field. With this patch, api v2 skips populating the peers array, sets the name to an empty string and the status to "disabled" in case `api.peer` is nil. Signed-off-by: Max Leonard Inden <IndenML@gmail.com> |
||
---|---|---|
.. | ||
v1 | ||
v2 |