prometheus-k8s-operator
prometheus-k8s-operator copied to clipboard
Changing name of an alert creates a new alert rule
Bug Description
We have just started to implement COS-lite stack into our production. When we create the charms, we add rules for grafana-agent to integrate onto prometheus, but when we change the name of a rule and refresh the application, a new rule gets created.
We were able to remove it by commented it out, push it with juju refresh, then remove the file and recreate the charm.
To Reproduce
- Include alert rules to a charm
- Pack it with charmcraft
- Deploy it
- Make relations between the charm -> grafana-agent -> COS-lite stack
- Check in grafana for alert rules
- Change alert name of a rule
- Pack it again with charmcraft
- Juju refresh
- Watch grafana for the new alert rule
Environment
Juju controller v.2.9.43 Clouds
- Microk8s (latest/stable) -> COS-lite (latest/stable)
- LXD (v5.0 LTS) -> different charms
Cross-Model using COS-lite and Grafana-Agent (edge)
Relevant log output
Will update this issue when I have reproduced the scenario.
Additional context
No response