Skip to content

Conversation

@timgriffiths
Copy link
Contributor

Summary

Fixes cert-manager Certificate resources being incorrectly marked as "Degraded" during renewal/issuance when the Ready condition is False with an "Issuing" message, but before the separate Issuing condition type is added.

Problem

When a cert-manager Certificate is being issued or renewed, there's a race condition in the condition updates:

  1. cert-manager first sets Ready=False with a message containing "Issuing" (e.g., "Issuing certificate as Secret does not exist")
  2. Only afterward does cert-manager add the separate type: Issuing condition

The existing health check (added in commit 8886874) only looks for the Issuing condition type, missing this transitional state. This causes certificates to briefly show as "Degraded" in ArgoCD during normal renewal operations.

Solution

This PR adds an additional check: when Ready=False, also check if the message contains "Issuing". If so, return "Progressing" status instead of "Degraded".

This aligns with the existing behavior that already returns "Progressing" when the Issuing condition type is present.

Changes

  • Modified resource_customizations/cert-manager.io/Certificate/health.lua to check for "Issuing" in the Ready condition message
  • Added test case progressing_issuing_message_only.yaml to cover this scenario

Checklist

  • Either (a) I've created an enhancement proposal and discussed it with the community, (b) this is a bug fix, or (c) this does not need to be in the release notes.
  • The title of the PR states what changed and the related issues number (used for the release note).
  • The title of the PR conforms to the Conventional Commits spec.
  • I've updated documentation as required by this PR.
  • I have signed my commits with DCO (gpg sign alone is not enough).
  • I have written unit and/or e2e tests for my change. PRs without these are unlikely to be merged.
  • My build is green (troubleshooting builds).
  • My new feature complies with the feature contribution guidelines.
  • If there are changes to the UI, I've included screenshots or videos.

@timgriffiths timgriffiths requested a review from a team as a code owner January 21, 2026 22:17
@bunnyshell
Copy link

bunnyshell bot commented Jan 21, 2026

🔴 Preview Environment stopped on Bunnyshell

See: Environment Details | Pipeline Logs

Available commands (reply to this comment):

  • 🔵 /bns:start to start the environment
  • 🚀 /bns:deploy to redeploy the environment
  • /bns:delete to remove the environment

Copy link
Contributor

@ppapapetrou76 ppapapetrou76 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM @timgriffiths but can you please sign-off your commits

…ng message

This fixes a race condition where cert-manager sets Ready=False with a message
containing 'Issuing' before the Issuing condition type is added. Previously,
this would incorrectly show the certificate as Degraded instead of Progressing.

The fix checks the Ready condition's message for 'Issuing' text when
Ready=False, treating it as Progressing rather than Degraded.

Signed-off-by: Tim Griffiths <griffiths.timothy@gmail.com>
Signed-off-by: Timothy Griffiths <griffiths.timothy@gmail.com>
@timgriffiths timgriffiths force-pushed the fix/cert-manager-certificate-issuing-message branch from bff5e98 to 438d91c Compare January 22, 2026 09:09
@timgriffiths
Copy link
Contributor Author

@ppapapetrou76 thank you for the review. Commit sign off fixed

Copy link
Member

@nitishfy nitishfy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants