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

OCP 4.15.0 is not correctly refreshing operator catalogs (imagePullPolicy: IfNotPresent)

XMLWordPrintable

    • Critical
    • Yes
    • Proposed
    • False
    • Hide

      None

      Show
      None
    • Hide
      * Previously, when updating to {product-title} 4.15 the CatalogSource never refreshed which caused the optional operators to fail to update. With this release, the image pull policy is changed to `Always` which enables the optional operators to update correctly. (link:https://issues.redhat.com/browse/OCPBUGS-30193[*OCPBUGS-30193*])
      ___________________________
      *Cause*: upgrade the OCP cluster to 4.15.0
      *Consequence*: the optional operators' new version never gets updated due to the CatalogSource never really refreshed
      *Fix*: replace the `IfNotPresent` with the `Always` image pull policy
      *Result*: Bug doesn’t present anymore.
      Show
      * Previously, when updating to {product-title} 4.15 the CatalogSource never refreshed which caused the optional operators to fail to update. With this release, the image pull policy is changed to `Always` which enables the optional operators to update correctly. (link: https://issues.redhat.com/browse/OCPBUGS-30193 [* OCPBUGS-30193 *]) ___________________________ *Cause*: upgrade the OCP cluster to 4.15.0 *Consequence*: the optional operators' new version never gets updated due to the CatalogSource never really refreshed *Fix*: replace the `IfNotPresent` with the `Always` image pull policy *Result*: Bug doesn’t present anymore.
    • Bug Fix
    • In Progress

      This is a clone of issue OCPBUGS-30132. The following is the description of the original issue:

      Description of problem:

      In OCP 4.14 the catalog pods in openshift-marketplace where defined as:
      
      $ oc get pods -n openshift-marketplace redhat-operators-4bnz4 -o yaml
      apiVersion: v1
      kind: Pod
      metadata:
      ...
        labels:
          olm.catalogSource: redhat-operators
          olm.pod-spec-hash: 658b699dc
        name: redhat-operators-4bnz4
        namespace: openshift-marketplace
      ...
      spec:
        containers:
        - image: registry.redhat.io/redhat/redhat-operator-index:v4.14
          imagePullPolicy: Always
      
      
      
      Now on OCP 4.15 they are defined as:
      apiVersion: v1
      kind: Pod
      metadata:
      ...
        name: redhat-operators-44wxs
        namespace: openshift-marketplace
        ownerReferences:
        - apiVersion: operators.coreos.com/v1alpha1
          blockOwnerDeletion: false
          controller: true
          kind: CatalogSource
          name: redhat-operators
          uid: 3b41ac7b-7ad1-4d58-a62f-4a9e667ae356
        resourceVersion: "877589"
        uid: 65ad927c-3764-4412-8d34-82fd856a4cbc
      spec:
        containers:
        - args:
          - serve
          - /extracted-catalog/catalog
          - --cache-dir=/extracted-catalog/cache
          command:
          - /bin/opm
      ...
          image: quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:7259b65d8ae04c89cf8c4211e4d9ddc054bb8aebc7f26fac6699b314dc40dbe3
          imagePullPolicy: Always
      ...
        initContainers:
      ...
        - args:
          - --catalog.from=/configs
          - --catalog.to=/extracted-catalog/catalog
          - --cache.from=/tmp/cache
          - --cache.to=/extracted-catalog/cache
          command:
          - /utilities/copy-content
          image: registry.redhat.io/redhat/redhat-operator-index:v4.15
          imagePullPolicy: IfNotPresent
      ...
      
      
      
      And due to `imagePullPolicy: IfNotPresent` on the initContainer used to extract the index image (referenced by tag) content, they are never really updated. 
      
      
          

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

          OCP 4.15.0    

      How reproducible:

          100%    

      Steps to Reproduce:

          1. wait for the next version of a released operator on OCP 4.15
          2.
          3.
          

      Actual results:

          Operator catalogs are never really refreshed due to  imagePullPolicy: IfNotPresent for the index image

      Expected results:

          Operator catalogs are periodically (every 10 minutes by default) refreshed

      Additional info:

          

            krizza@redhat.com Kevin Rizza
            openshift-crt-jira-prow OpenShift Prow Bot
            Jian Zhang Jian Zhang
            Votes:
            0 Vote for this issue
            Watchers:
            11 Start watching this issue

              Created:
              Updated:
              Resolved: