Cert-manager: The new certificate of apiversion cert-manager.io/v1alpha2 showing issues with (error validating data: ValidationError(Certificate.spec): unknown field "acme" in io.cert-manager.v1alpha2.Certificate.spec)

Created on 29 Mar 2020  路  2Comments  路  Source: jetstack/cert-manager

I have a certificate of the below format:

apiVersion: cert-manager.io/v1alpha2
kind: Certificate
metadata:
name: tls-$NAMESPACE-env-secret
spec:
secretName: tls-$NAMESPACE-env-secret
issuerRef:
name: $NAMESPACE-letsencrypt-$letsencrypt_type
kind: ClusterIssuer
commonName: $config_platform.$config_dns_base_suffix
dnsNames:

  • $config_platform.$config_dns_base_suffix
  • .$config_platform.$config_dns_base_suffix
    acme:
    config:

    • dns01:

      provider: azure-dns

      domains:



      • $config_platform.$config_dns_base_suffix


      • .$config_platform.$config_dns_base_suffix



When I apply with the right key value pairs then I get the below error:

_error: error validating "check.yaml": error validating data: ValidationError(Certificate.spec): unknown field "acme" in io.cert-manager.v1alpha2.Certificate.spec; if you choose to ignore these errors, turn validation off with --validate=false_

Expected behaviour:
The new certificate should get created without any issues.

Steps to reproduce the bug:
Kubernetes Version: 1.16
Certificate Manager: v0.14.1

When I try with the command as
kubectl apply -f certificate.yaml (Content as from the above)

Anything else we need to know?:

Environment details::

  • Kubernetes version (e.g. v1.10.2): 1.16
  • Cloud-provider/provisioner (e.g. GKE, kops AWS, etc): Azure
  • cert-manager version (e.g. v0.4.0): v0.14.1
  • Install method (e.g. helm or static manifests): Helm for cert manager and Static manifest for certificate

/kind bug

triagsupport

Most helpful comment

Why do they keep changing APIs. In past 1 year of using cert-manager, it was changed so drastically with the APIs twice. Its a pain to maintain.

All 2 comments

This isn't a bug, it's expected. There is no certificate.spec.acme field anymore (it was first deprecated in v0.8): https://cert-manager.io/docs/installation/upgrading/upgrading-0.7-0.8/#performing-an-incremental-switch-to-the-new-format

Please read through the DNS01 tutorial and use that to get setup instead 馃槃 perhaps whatever guide you are using is out of date? https://cert-manager.io/docs/tutorials/acme/dns-validation/

Why do they keep changing APIs. In past 1 year of using cert-manager, it was changed so drastically with the APIs twice. Its a pain to maintain.

Was this page helpful?
0 / 5 - 0 ratings