Description of problem: Run bundle-upgrade failed if the operator is installed with a FBC index image through traditional OLM way. Version-Release number of selected component (if applicable): operator-sdk version: "v1.20.0-ocp", commit: "4db4731ae75f2cccae951dd7ed98484662179c55", kubernetes version: "v1.24.1", go version: "go1.18.3", GOOS: "linux", GOARCH: "amd64" How reproducible: always Steps to Reproduce: 1. install operator through catalogsource $oc create -f catalogsource.yaml apiVersion: operators.coreos.com/v1alpha1 kind: CatalogSource metadata: name: upgradefbc-index namespace: testkaka spec: displayName: Test publisher: OLM-QE sourceType: grpc image: quay.io/olmqe/upgradefbc-index:v0.1 updateStrategy: registryPoll: interval: 15m $oc create -f og.yaml kind: OperatorGroup apiVersion: operators.coreos.com/v1 metadata: name: og-single namespace: testkaka spec: targetNamespaces: - testkaka $oc create -f sub.yaml apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: name: test namespace: testkaka spec: channel: alpha installPlanApproval: Automatic name: upgradefbc source: upgradefbc-index sourceNamespace: testkaka 2. oc get pods $ oc get pods NAME READY STATUS RESTARTS AGE 75d0b3dc04b4ab777d62672dbf403f153e93db06c90786c9a8779dbc4blrt4t 0/1 Completed 0 12m upgradefbc-controller-manager-85d9df559f-ln7x7 2/2 Running 0 12m upgradefbc-index-xwl9c 1/1 Running 0 12m 3. upgrade operator through run bundle-upgrade $operator-sdk run bundle-upgrade quay.io/olmqe/upgradefbc-bundle:v0.0.2 Actual results: $ oc logs quay-io-olmqe-upgradefbc-bundle-v0-0-2 Error: could not build index model from declarative config: duplicate package "upgradefbc" Usage: opm serve <source_path> [flags] Flags: --debug enable debug logging -h, --help help for serve -p, --port string port number to serve on (default "50051") -t, --termination-log string path to a container termination log file (default "/dev/termination-log") Global Flags: --skip-tls-verify skip TLS certificate verification for container image registries while pulling bundles --use-http use plain HTTP for container image registries while pulling bundles Expected results: upgrade success
Hi Jia, Just an update: PR https://github.com/operator-framework/operator-sdk/pull/5894 was created that fixes this issue. This fix will go into downstream during the next sync. Meanwhile, please do verify that the fix works and confirm the same. Thanks! Thanks, Rashmi
verified, will test after the pr merged to downstream.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Important: OpenShift Container Platform 4.11.0 bug fix and security update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2022:5069