Uploaded image for project: 'Service Binding'
  1. Service Binding
  2. APPSVC-1372

ClusterEnvironment healthcheck crash on invalid kubeconfig

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Normal Normal
    • Primaza 0.1
    • Primaza 0.1
    • Service Binding
    • None

      Description of problem:

      Control Plane crashes during healthchecks if an invalid kubeconfig is retrieved from a ClusterEnvironment's ClusterContext secret

      Prerequisites (if any, like setup, operators/versions):

      Steps to Reproduce

      diff --git a/test/acceptance/features/clusterEnvironmentHealthcheck.feature b/test/acceptance/features/clusterEnvironmentHealthcheck.feature
      index f821dea..6bcdaf9 100644
      --- a/test/acceptance/features/clusterEnvironmentHealthcheck.feature
      +++ b/test/acceptance/features/clusterEnvironmentHealthcheck.feature
      @@ -40,6 +40,18 @@ Feature: ClusterEnvironment's Healthchecks
               Then On Primaza Cluster "main", ClusterEnvironment "worker" state will eventually move to "Offline"
               And On Primaza Cluster "main", ClusterEnvironment "worker" status condition with Type "Online" has Reason "ErrorDuringHealthCheck"
       
      +    Scenario: Status change for ClusterEnvironment: ClusterContextSecret is updated incorrectly
      +        When On Primaza Cluster "main", "secret" named "primaza-kw" in "primaza-system" is patched
      +        """
      +        {
      +            "data": {
      +                "kubeconfig": ""
      +            }
      +        }
      +        """
      +        Then On Primaza Cluster "main", ClusterEnvironment "worker" state will eventually move to "Offline"
      +        And On Primaza Cluster "main", ClusterEnvironment "worker" status condition with Type "Online" has Reason "ErrorDuringHealthCheck"
      +
           Scenario: Status change for ClusterEnvironment: Worker cluster is deleted
               When Worker Cluster "worker" is deleted
               Then On Primaza Cluster "main", ClusterEnvironment "worker" state will eventually move to "Offline"
       

      Actual results:

      Scenario fails

      Expected results:

      Scenario passes

      Reproducibility (Always/Intermittent/Only Once):

      Always

      Build Details:

      Additional info:

              bmuthuka Baiju Muthukadan
              rh-ee-filario Francesco Ilario
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: