Skip to content

monitoring enabled false does not seem to do anything #818

Open
@joyartoun

Description

Describe the bug
According to the gitops operator documentation Setting

spec:
  monitoring:
    enabled: false

On the argocd instance yaml should disable and remove the prometheusrule created by the operator for that specific argocd instance. However the flag does not seem to do anything.

I think the bug in question lies in this block Where there is a check for if the flag Spec.Monitoring.DisableMetrics is true or defined. But no check for the flag Spec.Monitoring.enabled exists it seems.
There should be a way to keep the metrics but also disable the alerting rules, but setting Spec.Monitoring.DisableMetrics to true disables all of it.

To Reproduce
Steps to reproduce the behavior:
Set:

spec:
  monitoring:
    enabled: false

On the argocd instance.
Wait for the rule to be deleted.
Nothing happens.
Delete the rule manually and see that the operator recreates it.

Expected behavior
I expect the operator to remove the prometheus rule from the openshift cluster, as the documentation describes.

Additional context
Alerts from other teams argocd instances are flooding the openshift console notification bar.

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions