operator-framework / operator-sdk

SDK for building Kubernetes applications. Provides high level APIs, useful abstractions, and project scaffolding.
https://sdk.operatorframework.io
Apache License 2.0
7.2k stars 1.74k forks source link

FBC: catalog-build target in Makefile needs to be updated to generate an FBC catalog image #5832

Open rashmigottipati opened 2 years ago

rashmigottipati commented 2 years ago

Bug Report

What did you do?

The catalog-build target in Makefile still uses opm index add to generate a SQLite catalog index image. This needs to be updated to generating an FBC index image as we will be defaulting to using File-Based Catalogs once PR is merged into master.

How reproducible: Always

Steps to Reproduce:

  1. generate an operator through operator-sdk
  2. cat Makefile

What did you expect to see?

Generate the FBC index image in the following way: $ mkdir catalog $ opm generate dockerfile catalog $ mkdir catalog/xxxx $ opm init xxxx -c alpha -o yaml > catalog/xxxx/index.yaml $ opm render quay.io/test/xxxx:v1.0 -o yaml >> catalog/xxxx/index.yaml

What did you see instead? Under which circumstances?

Screen Shot 2022-06-06 at 11 27 34 AM

Environment

$ operator-sdk version

operator-sdk version: "v1.20.0-16-g38b8b8d9", commit: "38b8b8d949578a44fb23319e56c242fd620523ca", kubernetes version: "v1.23", go version: "go1.17.4", GOOS: "linux", GOARCH: "amd64"

$ go version (if language is Go)

go version: "go1.17.4"

jmrodri commented 2 years ago

I removed the release-blocker label because this turns out to be more of an RFE than a bug.

asmacdo commented 2 years ago

Removed the milestone for re-triage. @jmrodri thoughts?

everettraven commented 1 year ago

There was some internal discussion a while back about what possibly needs to be done to resolve this. To make it more transparent and easier to find I wanted to copy that discussion over here:

Things that likely need to be done:

everettraven commented 1 year ago

/unassign jmrodri

joelanford commented 1 year ago

I don't think this one is ready to be worked. The existing makefile targets assume an imperative flow where new bundles can be added to existing catalogs. File-based catalogs are a major change because an individual bundle (which is the context of an individual commit of an operator-sdk project) no longer carries upgrade edge information necessary to add that bundle to a catalog.

IMO any work related to this is blocked until we have more answers about the way we expect upstream users to build and maintain file-based catalogs.

openshift-bot commented 1 year ago

Issues go stale after 90d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle stale. Stale issues rot after an additional 30d of inactivity and eventually close. Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle stale

everettraven commented 1 year ago

/lifecycle frozen

everettraven commented 1 year ago

/lifecycle frozen

Nilesh20 commented 1 year ago

Facing same issue. Any update ? How/When can we have FBC: catalog-build target in Makefile ?

jmrodri commented 1 year ago

Facing same issue. Any update ? How/When can we have FBC: catalog-build target in Makefile ?

@Nilesh20 this issue is still blocked by Joe's comment in https://github.com/operator-framework/operator-sdk/issues/5832#issuecomment-1377612560

sukhil-suresh commented 9 months ago

Is there any plan to update the opm index add command to support File Based Catalogs (FBC), any time soon? This ticket has been open for 1.5 years. We depend on the opm index commands for our automation to test Operator upgrades and install scenarios. The RedHat Marketplace catalog moved to FBC long ago with OpenShift 4.11. Kindly provide an update. Thanks.

adambkaplan commented 2 months ago

This is important for operators that expect OLM to manage install and uninstall with file-based catalogs. The current Makefile target is in fact broken if a developer wants to "shim" their bundle into an existing FBC catalog.

For the Red Hat OpenShift Builds operator, I was able to template a test FBC catalog that could be built and deployed as part of a developer "inner loop": https://github.com/redhat-openshift-builds/operator/pull/38