Uploaded image for project: 'Red Hat Developer Hub Bugs'
  1. Red Hat Developer Hub Bugs
  2. RHDHBUGS-1792

Failed to List Cluster Resources in Janus IDP Backstage Plugin OCM Backend Dynamic

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Blocker Blocker
    • 1.2
    • 1.2
    • None
    • 1
    • False
    • Hide

      None

      Show
      None
    • False
    • Hide
      Cause – The OCM Plugin ReadMe had no information about how to configure OCM on a K8s cluster.

      Consequence – The OCM plugin couldn't fetch clusters.

      Fix – Updated the ReadMe with the link to configure OCM on a k8s cluster. Also, added steps to allow access to the OCM backend plugin when the RBAC permission framework is enabled.

      Result – The OCM plugin can be configured to fetch and display clusters in the OCM front-end.
      Show
      Cause – The OCM Plugin ReadMe had no information about how to configure OCM on a K8s cluster. Consequence – The OCM plugin couldn't fetch clusters. Fix – Updated the ReadMe with the link to configure OCM on a k8s cluster. Also, added steps to allow access to the OCM backend plugin when the RBAC permission framework is enabled. Result – The OCM plugin can be configured to fetch and display clusters in the OCM front-end.
    • Bug Fix
    • Done
    • RHDH F&UI plugins 3256

      There seems to be an issue with accessing ManagedClusters using a newly created ServiceAccount. Despite correctly configuring a ClusterRole with the necessary permissions and binding it to the ServiceAccount using a ClusterRoleBinding, attempts to access ManagedClusters result in a "forbidden" error.

      Steps to Reproduce:

      Apply the ClusterRole YAML to create the ClusterRole with permissions to access ManagedClusters.
      Apply the ClusterRoleBinding YAML to bind the ClusterRole to the ServiceAccount
      Verify that the ClusterRoleBinding is correctly applied and associated with the desired ServiceAccount and ClusterRole.

      Configurations

              - package: ./dynamic-plugins/dist/janus-idp-backstage-plugin-ocm-backend-dynamic
                disabled: false
                pluginConfig:             catalog:               providers:                 ocm:                   default:                     name: testCluster # Can be any arbitrary name supported by kubernetes
                          url: ${OCM_CLUSTER_URL}
                          serviceAccountToken: ${OCM_CLUSTER_TOKEN}
                          skipTLSVerify: true
                          owner: janus-authorsUSTER_TOKEN}
      skipTLSVerify: true
      owner: janus-authors

      Server error:

       

      2024-05-02T17:11:50.938Z rootHttpRouter info ::ffff:172.17.10.58 - - [02/May/2024:17:11:50 +0000] "GET /api/catalog/entities?filter=kind%3DResource%2Cspec.type%3Dkubernetes-cluster HTTP/1.1" 304 - "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36" type=incomingRequest 3602024-05-02T17:11:51.131Z backstage error Request failed with status 404 404 page not found 361type=errorHandler statusCode=404 name=404 page not found 362stack=404 page not found 363: 404 page not found

      Build details:
      OC version: 4.14.20_1558 on IBM Cloud

      Installation method: Helm Chart
      RHDH Version: 1.2.0
      Backstage Version: 1.25.2

        1. clusterrole.yaml
          0.2 kB
        2. clusterrolebinding.yaml
          0.3 kB
        3. serviceaccount.yaml
          0.1 kB
        4. image-2024-05-02-14-17-17-696.png
          image-2024-05-02-14-17-17-696.png
          209 kB

              dsantra12 Debsmita Santra
              gustavolira Gustavo Lira Silva
              RHIDP - Frontend Plugins & UI
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: