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

feat: add support for disabling alert rules forwarding #252

Merged
merged 19 commits into from
Feb 10, 2025

Conversation

lucabello
Copy link
Contributor

@lucabello lucabello commented Feb 4, 2025

Issue

Partially addresses #154

Solution

Add a juju config option named disable_forwarding_alert_rules (the name is up for discussion) to (you guessed it) disable the forwarding of alert rules, including grafana-agent's own alerts.

This PR achieves that by adding the aforementioned config option, which defaults to false, and passing None as alert_rules_path to the PrometheusRemoteWriteConsumer.

In tandem with canonical/prometheus-k8s-operator#673 this should address the isssue for grafana-agent.

Testing Instructions

Pack and deploy both this charm and Prometheus, connect them, and test this new flag.

Screenshots

Screenshot-2025-02-05_11-02

@lucabello
Copy link
Contributor Author

Making it a draft because this PR is useful for code review, but it shouldn't be merged before the Prometheus one.

@lucabello lucabello merged commit 6ef4f2c into main Feb 10, 2025
10 of 12 checks passed
@lucabello lucabello deleted the feature/disable-alerts branch February 10, 2025 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants