Certificate resource and the operator provisions the actual TLS certificate; delete the Certificate and the operator will clean up or re-create associated objects as needed.
This lesson walks through how to read operator status and conditions using cert-manager as a concrete example. In both exams and production troubleshooting, you often need to infer what an operator is doing without access to its source code. cert-manager exposes several CRDs that map to TLS lifecycle concepts (Certificate, Issuer, CertificateRequest, Order, Challenge, etc.). The operator watches these resources and reconciles them.
Verify cert-manager CRDs exist
First, confirm that cert-manager’s CRDs are installed:Quick reference: cert-manager CRDs and their roles
Create a test Issuer (self-signed)
To issue a certificate you need two things: an Issuer that defines how the certificate will be issued and a Certificate resource that declares what you want. For quick testing, a self-signed Issuer is convenient. Save this manifest as/root/selfsigned-issuer.yaml:
Status block and the Conditions entry reporting Ready: True. This indicates the operator successfully reconciled the Issuer.
Create a Certificate that uses the Issuer
Next, create aCertificate that references the self-signed Issuer. Save this as /root/test-certificate.yaml:
Message and Reason fields provide the operator’s human-readable summary of the resource state. When troubleshooting, these are your primary starting points.
Inspect the Secret created by the operator
cert-manager stores the issued certificate and private key in a Kubernetes Secret named as specified bysecretName in the Certificate resource.
Check the Secret:
Certificate resource.
Demonstrate the reconciliation loop
To see reconciliation in action, delete the Secret and watch the operator recreate it:Always start troubleshooting custom resources by inspecting their
status.conditions. Use kubectl describe <kind> <name> -n <namespace> (or kubectl get <kind> <name> -n <namespace> -o yaml) to see the operator-reported Status, Reason, human-readable Message, and related events.Key takeaways (exam & production)
- Use
kubectl getandkubectl describeon custom resources to read their status and conditions. The operator reports its view through the resource’sstatus. - Operators continuously reconcile and will restore resources they manage. Deleting dependent resources (e.g., Secrets created by an operator) may result in them being recreated automatically.
- If a resource is not in the desired state,
status.conditionsusually contains aFalsecondition with aReasonandMessagethat help diagnose what went wrong. Always check events shown bykubectl describeas well.
Links and references
- cert-manager documentation: https://cert-manager.io/docs/
- Kubernetes documentation: https://kubernetes.io/docs/