Uploaded image for project: 'Cluster Observability Operator'
  1. Cluster Observability Operator
  2. COO-288

DevConsole metrics forbidden when login as general user

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Blocker Blocker
    • 0.4.0
    • None
    • korrel8r
    • False
    • Hide

      None

      Show
      None
    • False
    • None

      Log in Dev console as a general user , Metrics are forbidden when navigated from Dev-Console->observe->logs->metrics

      https://console-openshift-console.apps.anlimag16.qemag.azure.devcluster.openshift.com/monitoring/query-browser?query0=%7Bnamespace%3D%22app2-testuser-1%22%2Cpod%3D%22centos-logtest-p4vtb%22%7D

      Same query can return value using observe->metrics-custom Query

      Step to reproduce:

      1. deploy coo and enable LoggingUI Plugin TroubeShootPannel Plugin.

      2. create projects, alert and assign roles o general user.

      echo "# grant ${user_name} view logs/alerts to ${user_namespace}"
      oc -n ${user_namespace} policy add-role-to-user view ${user_name}
      oc -n ${user_namespace} policy add-role-to-user cluster-logging-application-view ${user_name}
      oc -n ${user_namespace} policy add-role-to-user monitoring-rules-edit ${user_name}
      oc -n ${user_namespace} policy add-role-to-user cluster-monitoring-view  ${user_name}
      

      3. View Logs, metrics, alert in dev-console as general user
      Result: The general user can view logs, alert and metrics

      4. Click the metrics link in log record.

      Actual result:

      Metrics are forbidden when navigated from Dev-Console->observe->logs->metrics

        1. create-infra-app-logs-alerts.sh
          3 kB
        2. screenshot-2.png
          screenshot-2.png
          23 kB
        3. screenshot-3.png
          screenshot-3.png
          70 kB
        4. screenshot-4.png
          screenshot-4.png
          22 kB

            [COO-288] DevConsole metrics forbidden when login as general user

            Errata Tool added a comment -

            Since the problem described in this issue should be resolved in a recent advisory, it has been closed.

            For information on the advisory (Cluster Observability Operator 0.4.0), and where to find the updated files, follow the link below.

            If the solution does not work for you, open a new bug report.
            https://access.redhat.com/errata/RHEA-2024:6699

            Errata Tool added a comment - Since the problem described in this issue should be resolved in a recent advisory, it has been closed. For information on the advisory (Cluster Observability Operator 0.4.0), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHEA-2024:6699

            Anping Li added a comment -

            The generic can display the metrics from Logging-metrics in 0.4.0.

             

            Anping Li added a comment - The generic can display the metrics from Logging-metrics in 0.4.0.  

            Anping Li added a comment -

            Verified on 4.16 using the PR https://github.com/openshift/logging-view-plugin/pull/211
            Verified on 4.17 using the PR https://github.com/openshift/logging-view-plugin/pull/211 and openshift/monitoring-plugin#164

            Anping Li added a comment - Verified on 4.16 using the PR https://github.com/openshift/logging-view-plugin/pull/211 Verified on 4.17 using the PR https://github.com/openshift/logging-view-plugin/pull/211 and openshift/monitoring-plugin#164

            Hongyan Li added a comment - - edited

            Hongyan Li added a comment - - edited rhn-support-anli     According to the following doc, have you tried assign role cluster-monitoring-view to the genernal user? https://docs.openshift.com/container-platform/4.16/observability/monitoring/managing-metrics.html#querying-metrics-for-us[…]veloper_managing-metrics

              gbernal@redhat.com Gabriel Bernal
              rhn-support-anli Anping Li
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: