0

I am trying to upgrade a chart but when I run upgrade command, upgrade fails with the following error.

nit:~/copy> helm upgrade chart-repository chart-repository/
Error: UPGRADE FAILED: "chart-repository" has no deployed releases

but when I do helm list -A , it looks to me it is deployed.

nit:~/copy> helm ls -A
NAME                NAMESPACE   REVISION    UPDATED                                 STATUS      CHART                   APP VERSION
chart-repository    charts      1           2021-06-08 14:43:05.186875759 +0000 UTC deployed    chart-repository-0.0.16 0.0.14   

So, why is the upgrade failing? i am using helm 3.6.0.

Thanks

1

You're missing namespace in the upgrade command. Following should work:

helm upgrade chart-repository chart-repository/ -n charts
3
  • hi, thanks. that worked but i am getting this error. any idea why i might be guessing this error: UPGRADE FAILED: cannot patch "chart-repository-chartmuseum" with kind Deployment: Deployment.apps "chart-repository-chartmuseum" is invalid: spec.selector: Invalid value: v1.LabelSelector{MatchLabels:map[string]string{"app.kubernetes.io/instance":"chart-repository", "app.kubernetes.io/name":"chartmuseum"}, MatchExpressions:[]v1.LabelSelectorRequirement(nil)}: field is immutable
    – ray an
    Jun 8 at 20:11
  • So selector changed and it does not support this kind of upgrade. What you can do - delete this deployment via kubectl (kubectl delete deployment chart-repository-chartmuseum) - and then re-do the helm upgrade command. Note that this would cause some downtime.
    – taleodor
    Jun 8 at 21:50
  • + Feel free to join my Discord for quick questions - discord.gg/UTxjBf9juQ - I curate that and here I can miss something
    – taleodor
    Jun 8 at 21:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.