Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-29208

ConfigurationPolicy generated by ACM Policy Generator Plugin crashes hub cluster.

XMLWordPrintable

    • Important
    • None
    • CNF RAN Sprint 249, CNF RAN Sprint 250, CNF RAN Sprint 251, CNF Ran Sprint 252, CNF Ran Sprint 253
    • 5
    • Rejected
    • False
    • Hide

      None

      Show
      None

      Description of problem:

      When using ACM Gen templates, for ConfigurationPolicy kinds, the name of the object and the inner template names are the same.
      In comparison the PGT plugin, adds "-config" to the name of the inner template. This leads to overloaded keys in the
      clusterGroupUpgrade.Status.SafeResourceNames map.
      As a result, TALM uses a wrongly cached safe name which is longer than the maximum length of 62 for the policy name and namespace. When this happens policies are created in the ztp-install namespace but never deleted, leading to the hub cluster becoming unreacheable.
        

      Version-Release number of selected component (if applicable):

      4.15

      How reproducible:

      100%

      Steps to Reproduce:

      1- Deploy a ZTP spoke cluster using ACM templates
      
      2- verify that the name of the root policy is the same as the inner template inside the policy:
      apiVersion: policy.open-cluster-management.io/v1
      kind: Policy
      metadata:   
        name: group-du-sno-v4.14-config-policy  ------------------------
        namespace: ztp-group                                           |
      spec:                                                            |
        disabled: false                                                |
        policy-templates:                                              |
        - objectDefinition:                                            =
            apiVersion: policy.open-cluster-management.io/v1           |
            kind: ConfigurationPolicy                                  |
            metadata:                                                  |
              name: group-du-sno-v4.14-config-policy--------------------
            spec:
         

      Actual results:

      TALM creates policies in the ztp-install namespace that until the cluster crashes due to lack of resources

      Expected results:

      TALM starts remediating policies

      Additional info:

       

       

       

              deliedit@redhat.com David Elie-Dit-Cosaque
              deliedit@redhat.com David Elie-Dit-Cosaque
              Joshua Clark Joshua Clark
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: