Skip to content

Use 2 chart for upgrading the crds using helm - #234

Merged
alicefr merged 4 commits into
mainfrom
helm-upgrade
Oct 16, 2026
Merged

alicefr merged 4 commits into
mainfrom
helm-upgrade

Conversation

@alicefr

@alicefr alicefr commented Oct 15, 2026 •

Copy link
Copy Markdown
Collaborator

Helm doesn't upgrade or delete the crds (see the official documentation),. In the official documentation, one of the method to solve this is to create a separte chart for the crds, in this way the can be installed and upgrade using helm. In particular, we are interested in the fact that the crds are released as oci artifact.

Additionally, the documentation now also covers the upgrade and uninstall paths

@alicefr
alicefr marked this pull request as draft October 15, 2026 11:47
@alicefr alicefr changed the title Describe upgrade with helm Use 2 chart for upgrading the crds using helm Oct 15, 2026
@alicefr
alicefr marked this pull request as ready for review October 15, 2026 12:04
@alicefr

alicefr commented Oct 15, 2026

Copy link
Copy Markdown
Collaborator Author

@Mergifyio backport release-0.2

@mergify

mergify Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

backport release-0.2

✅ Backports have been created

Details

Comment thread docs/src/helm.md Outdated

## Upgrade

Upgrade both charts. The CRD chart must be upgraded first:

@cheesesashimi cheesesashimi Oct 15, 2026 •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We might want to declare that the CRD chart is a required dependency of the operator chart so that the ordering will be preserved and make the installation / upgrade process less error-prone: https://helm.sh/docs/helm/helm_dependency/.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now it does use the crds chart as dependency. Thanks for the suggestion!

CRDs are shipped in a separate sub-chart (bootc-operator-crds) and
declared as a Helm dependency of the operator chart. This keeps CRDs
in templates/ so helm upgrade can update them, while preserving
install/upgrade ordering automatically.

The dependency is conditional on crds.install (default true), allowing
users who manage CRDs separately to disable it.

Assisted-by: AI
Signed-off-by: Alice Frosi <afrosi@redhat.com>
Publish the CRD chart to the OCI registry before the operator chart.
Run helm dependency build for the operator so the CRD sub-chart is
bundled into the package. Sync the dependency version at release time.

Assisted-by: AI
Signed-off-by: Alice Frosi <afrosi@redhat.com>
Document single-chart install and upgrade using the CRD dependency.
Include instructions for managing CRDs separately with crds.install=false.

Assisted-by: AI
Signed-off-by: Alice Frosi <afrosi@redhat.com>
Assisted-by: AI
Signed-off-by: Alice Frosi <afrosi@redhat.com>
@alicefr
alicefr force-pushed the helm-upgrade branch 2 times, most recently from d2c698d to 3fe0fc9 Compare October 15, 2026 14:16
@alicefr
alicefr requested a review from cheesesashimi October 15, 2026 14:18
@alicefr

alicefr commented Oct 15, 2026

Copy link
Copy Markdown
Collaborator Author

Tested created (and deleted already) a draft release for 0.2.1 and the installation works as expected

Comment thread docs/src/helm.md
Comment on lines +121 to +123
> **Warning**: uninstalling the chart also removes the CRDs and all
> their instances cluster-wide.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could we have this documented for roll back as well, same will happen for that when we change crd.install from true to false to previous chart without running helm unistall?

@alicefr alicefr Oct 16, 2026 •

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not every project support rollbacks. In fact, it might be disruptive if we add new required fields to the api and to rollback to the previous version. Can we leave rollback out of scope?

@alicefr
alicefr merged commit 18e350f into main Oct 16, 2026
15 checks passed
@alicefr
alicefr deleted the helm-upgrade branch October 16, 2026 05:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants