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

The operator recommended namespace is incorrect after change installation mode to "A specific namespace on the cluster"

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • None
    • 4.13
    • Management Console
    • None
    • None
    • Proposed
    • False
    • Hide

      None

      Show
      None
    • NA

      Description of problem:

      The operator recommended namespace is incorrect after change installation mode to "A specific namespace on the cluster"
      When both annotation operatorframework.io/suggested-namespace-template & operatorframework.io/suggested-namespace are defined in CSV. The Operator recommended Namespace should use the value difined in suggested-namespace-template

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

      4.13.0-0.nightly-2022-12-05-155739

      How reproducible:

      Always

      Steps to Reproduce:

      1. Create Catalog source
      apiVersion: operators.coreos.com/v1alpha1
      kind: CatalogSource
      metadata:
        name: test
        namespace: openshift-marketplace
      spec:
        displayName: test
        image: 'quay.io/xiyuzhao/flux-operator-index:latest'   
        sourceType: grpc
      2. Go to page /operatorhub/subscribe?pkg=flux&catalog=test55684&catalogNamespace=openshift-marketplace&targetNamespace=openshift-marketplace 
      3. Change Installation mode to "A specific namespace on the cluster"
      4. Check if the Operator recommended Namespace is the same value (testxi3210) defined in operatorframework.io/suggested-namespace-template

      Actual results:

      The Operator recommended Namespace is using the value that defined in operatorframework.io/suggested-namespace

      Expected results:

      The value should use operatorframework.io/suggested-namespace-template, but not operatorframework.io/suggested-namespace value

      Additional info:

      CSV definition on annotation section:
          operatorframework.io/suggested-namespace-template: >-            {"kind":"Namespace","apiVersion":"v1","metadata":{"name":"testxi3210","labels":{"foo":"testxi3120"},"annotations":{"openshift.io/node-selector":"","baz":"testxi3120"}},"spec":{"finalizers":["kubernetes"]}}
          operatorframework.io/suggested-namespace: flux-system
      
      Based UserStory: https://issues.redhat.com/browse/CONSOLE-3120

              sgoodwin_redhat Steve goodwin
              rhn-support-xiyuzhao Xiyun Zhao
              Xiyun Zhao Xiyun Zhao
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: