Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes to the "app.kubernetes.io/managed-by" label breaks Helm upgrades #218

Open
sonnysideup opened this issue Mar 14, 2024 · 2 comments

Comments

@sonnysideup
Copy link

Overview

I'm attempting to upgrade our Weaviate Helm chart version but unfortunately the changes are invalid and so Kubernetes rejects them.

Current version: 16.8.1
Desired version: 16.8.6
Error Message:

  Error: UPGRADE FAILED: an error occurred while rolling back the release. original upgrade error: cannot patch "weaviate" with kind StatefulSet: StatefulSet.apps "weaviate" is invalid: spec: Forbidden: updates to statefulset spec for fields
 other than 'replicas', 'ordinals', 'template', 'updateStrategy', 'persistentVolumeClaimRetentionPolicy' and 'minReadySeconds' are forbidden: no Secret with the name "weaviate-aws" found     

#193, which was merged into release v16.8.2, breaks our ability to perform a helm upgrade. Specifically, changing the StatefulSet.spec.volumeClaimTemplates[*].metadata.labels is strictly forbidden by Kubernetes; offending change here.

I would recommend a couple of things here:

  1. Start using a named template inside_helpers.tpl to apply your labels to resources. It seems like you have to manually update labels on all your resources instead of using a macro.
  2. Provide some guidance on upgrade strategy for this particular bug.
@sonnysideup
Copy link
Author

ping!

@phlegx
Copy link

phlegx commented Apr 10, 2024

I think I'm facing the same issues:

│ Error: cannot patch "weaviate" with kind StatefulSet: StatefulSet.apps "weaviate" is invalid: spec: Forbidden: updates to statefulset spec for fields other than 'replicas', 'template', 'updateStrategy', 'persistentVolumeClaimRetentionPolicy' and 'minReadySeconds' are forbidden

How can we solve this? Should we destroy and recreate the statefulset? I see not much other options tbh. @sonnysideup did you maybe find a solution here in the meanwhile?

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

No branches or pull requests

2 participants