feat: add percentage-based certificate expiry notifications#6840
Open
AnuragEkkati wants to merge 6 commits intolouislam:masterfrom
Open
feat: add percentage-based certificate expiry notifications#6840AnuragEkkati wants to merge 6 commits intolouislam:masterfrom
AnuragEkkati wants to merge 6 commits intolouislam:masterfrom
Conversation
- Add support for lifetime percentage thresholds in addition to days - Calculate percentRemaining for certificates based on total lifetime - Support dashboard tag colors to use 25% threshold. Fallback 7 days - Provide option in UI settings to configure percentage thresholds (1-100%) - Gracefully handle certificates without validFrom (Globalping monitors) This feature fixes louislam#6821
c726d50 to
0930867
Compare
If I understand this correctly, you first convert the total and remaining time to a daycount and then calculate the percentage. I belive this could cause issues with extremely short lived certificates. For example step-ca recommends validity periods of only one day. If I understand the code correctly it would show 100% and then immediately 0%. Though If the library supports floating point days, this isn't an issue. |
Contributor
Author
|
@CommanderStorm can you please review or assign reviewer for this when you find time. Thanks |
Contributor
Author
|
@CommanderStorm can you please assign some reviewer to this PR when you find time. Thanks |
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.
Summary
In this pull request, the following changes are made:
This feature fixes #6821
Please follow this checklist to avoid unnecessary back and forth (click to expand)
I understand that I am responsible for and able to explain every line of code I submit.
AI Usage
Used Cursor AI IDE to review the changes and highlight corner conditions to be explored.
Screenshots for Visual Changes
Notifications Tab:

Webhook Notification:

Status Page :

Tested by configuring 95% of cert validity if it turns red ( reverted to 25% in code )
Stdout Logs:
