Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support multiple alert manager replicas #514

Open
BryanFauble opened this issue Oct 6, 2024 · 3 comments
Open

Support multiple alert manager replicas #514

BryanFauble opened this issue Oct 6, 2024 · 3 comments
Labels
chart:signoz Issue related to signoz helm chart good first issue Good for newcomers

Comments

@BryanFauble
Copy link

In this helm chart it looks like 1 url is ever used/considered:

{{- define "alertmanager.url" -}}

Ask:
When running multiple replicas of alert mamager (https://github.com/SigNoz/alertmanager) allow for any alerts to be sent to 1 or more configured replicas.

Taken from the Readme of the signoz fork of alertmanager it supports the overall ask of this issue, it shows how it expects prometheus to point at multiple alert manager instances:

To point your Prometheus 1.4, or later, instance to multiple Alertmanagers, configure them in your prometheus.yml configuration file, for example:

alerting:
  alertmanagers:
  - static_configs:
    - targets:
      - alertmanager1:9093
      - alertmanager2:9093
      - alertmanager3:9093

Important: Do not load balance traffic between Prometheus and its Alertmanagers, but instead point Prometheus to a list of all Alertmanagers. The Alertmanager implementation expects all alerts to be sent to all Alertmanagers to ensure high availability.

Here are more links to code where changes are likely needed:

  1. value: http://{{ include "alertmanager.url" . }}/api/
  2. - {{ include "alertmanager.url" . }}
@grandwizard28
Copy link
Contributor

Hi @BryanFauble,
Thank you for opening this issue!

Would you be willing to contribute a PR for this?

@grandwizard28 grandwizard28 added chart:signoz Issue related to signoz helm chart good first issue Good for newcomers labels Oct 13, 2024
@BryanFauble
Copy link
Author

Thanks @grandwizard28 ,

This is something that gives a trivial benefit so I don't want to spend time on it for now.

Something of a larger benefit that I started to look at was starting to consider how k8s secrets might be used to configure things like the clickhouse password. However, there was some more work to consider how stuff like the traces url could also be fed in as it includes the username/password as well:

  1. main...BryanFauble:charts-signoz:main
  2. https://github.com/BryanFauble/charts-signoz/blob/7a29318aabc8bccab36a4db3aaf3bf7e71fb27df/charts/signoz/templates/_clickhouse.tpl#L234

The secretFrom stanza was something that the underlying clickhouse implementation is doing: https://altinity.com/blog/clickhouse-confidential-using-kubernetes-secrets-with-the-altinity-operator

@grandwizard28
Copy link
Contributor

Let's discuss this on a separate issue: #525.

I'd like to keep this open for supporting multiple alert managers :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chart:signoz Issue related to signoz helm chart good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants