Repository navigation
fix: cap autoTls certificate lifetime to the newest CA's remaining lifetime - #777
Merged
Merged
Conversation
xeniape
marked this pull request as ready for review
November 16, 2026 09:31
NickLarsenNZ
self-requested a review
November 16, 2026 13:38
NickLarsenNZ
previously approved these changes
Nov 17, 2026
NickLarsenNZ
left a comment
Member
There was a problem hiding this comment.
LGTM. I left some comments. Nothing major, just some suggestions.
I do think we should hold off on merging it until after the release, just so it has some time to soak in our regular tests.
NickLarsenNZ
approved these changes
Nov 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes #753
This PR
autoGenerateisfalse, but it also appeared (according to Claude) when caCertificateLifetime < 5 × caCertificateRetirementDuration, the cap here also fixes that situationTlsGenerate::get_or_create_k8s_certificate. I tried it first but it wasn't necessary and the whole function seems to have grown over time and was tangled with different scenarios, tried refactoring but just confused myself with all the calculations. Can confirm this one though autoTls: calculation for secure maximum certificate lifetimes so that all pods that are deployed trust every other deployed pod is too loose #754 -> according to Claude the fix would be, but I didn't test or include it in the PR:Release Note
Previously
autoTlscertificate mounts could fail whenautoGeneratewas set to false or in some rarecaCertificateLifetimeandcaCertificateRetirementDurationconfiguration combinations. Now the certificate lifetimes are capped by the CA lifetime that signs them, consequently fixing these mount failures. If the certificate lifetime gets reduced by this cap, the affected Pod will receive a Pod Event Warning to notify the user.Definition of Done Checklist
Author
Reviewer
Acceptance
type/deprecationlabel & add to the deprecation scheduletype/experimentallabel & add to the experimental features tracker