feat: allow filtering of expired CA certs #633
+550
−16
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 #625
This PR introduces the ability to filter out expired or soon-to-expire CA certificates from TrustStores and secret volumes by specifying a threshold (a duration, like
1d
). If a CA expires within this duration or is already expired it won't be published by secret-operator.Currently, all CA certificates are published, even expired ones.
Features:
caExpiryThreshold
field: Added to TrustStore CRD spec to configure minimum remaining CA lifetimesecrets.stackable.tech/backend.autotls.ca.expiry-threshold
annotation for controlling CA expiry filtering in volumesIf a threshold is not specified, all CAs (including expired ones) are published as before, so this change should be backwards compatible.
I also added a new integration test
tls-ca-expiry-threshold
for this feature.CRD change decision: #632
Definition of Done Checklist
Author
Reviewer
Acceptance
type/deprecation
label & add to the deprecation scheduletype/experimental
label & add to the experimental features tracker