4

I removing other versions from cert-manager. After that i install the new version with helm using.

Installation works fine.

but when i use the command:

$ kubectl get orders,challenges,clusterissuers

Error from server: request to convert CR from an invalid group/version: acme.cert-manager.io/v1alpha2
Error from server: request to convert CR from an invalid group/version: acme.cert-manager.io/v1alpha2
Error from server: request to convert CR from an invalid group/version: cert-manager.io/v1alpha2

The CRDs:

Name:         orders.acme.cert-manager.io
Namespace:    
Labels:       app=cert-manager
              app.kubernetes.io/instance=cert-manager
              app.kubernetes.io/managed-by=Helm
              app.kubernetes.io/name=cert-manager
              app.kubernetes.io/version=v1.8.2
              helm.sh/chart=cert-manager-v1.8.2
Annotations:  cert-manager.io/inject-ca-from-secret: cert-manager/cert-manager-webhook-ca
              meta.helm.sh/release-name: cert-manager
              meta.helm.sh/release-namespace: cert-manager
API Version:  apiextensions.k8s.io/v1
Kind:         CustomResourceDefinition
....

    Last Transition Time:  2022-06-24T15:25:23Z
    Message:               no conflicts found
    Reason:                NoConflicts
    Status:                True
    Type:                  NamesAccepted
    Last Transition Time:  2022-06-24T15:25:23Z
    Message:               the initial names have been accepted
    Reason:                InitialNamesAccepted
    Status:                True
    Type:                  Established
  Stored Versions:
    v1

i dont found the CR where still using cert-manager.io/v1alpha2 and acme.cert-manager.io/v1alpha2

1 Answers1

1

First of all, suggest to backup all your objects (certs, orders, issuer, clusterissuer, etc. with velero for example) !

Cert-manger documentation suggests using the cert-manager cli as:

cmctl upgrade migrate-api-version

You may need --skip-stored-version-check if you already tried to fix CRD api manually (like described in this issue):

cmctl upgrade migrate-api-version --skip-stored-version-check

Finally, if it's failing with the same message, install the 1.6.3 (if CRD is manually installed, upgrade CRD with 1.6.3) and repeat the command cmctl upgrade migrate-api-version.

At last, you can upgrade minor version one by one (1.7, 1.8, etc.) as recommended

Zied
  • 326
  • 2
  • 8