Search code examples
azurekubernetesazure-akscert-manager

How can I issue a certificate after I've moved to a new cluster?


I setup up a prototype cluster in Azure Kubernetes Service to test the ability to configure HTTPS ingress with cert-manager. I was able to make everything work, now I'm ready to setup my production environment.

The problem is I used the sub domain name I needed (sub.domain.com) on the prototype and now I can't seem to make Let's Encrypt give a certificate to the production cluster.

I'm still very new to Kubernetes and I can't seem to find a way to export or move the certificate from one to the other.

Update:

It appears that the solution provided below would have worked, but it came down to needing to suspend/turnoff the prototype's virtual machine. Within a couple minutes the production environment picked up the certificate.


Solution

  • you can just do something like:

    kubectl get secret -o yaml
    

    and just copy\paste your certificate secret to a new cluster, or use something like heptio ark to do backup\restore.

    ps. I dont know why it wouldn't let you create a new cert, at worst you would need to wait 7 days for your rate limit to refresh.