Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add metrics for certificate expiration date #131

Merged
merged 1 commit into from
Jun 13, 2023
Merged

Conversation

MartinWeindel
Copy link
Member

@MartinWeindel MartinWeindel commented Jun 13, 2023

What this PR does / why we need it:
A new metrics named cert_management_cert_object_expire has been added. It provides the expiration date as Unix time (the number of seconds elapsed since January 1, 1970 UTC) for each Certificate object.

If the metrics is collected by Prometheus, the remaining days before expiration can be calculated with PromQL expression

(cert_management_cert_object_expire-time())/86400

Which issue(s) this PR fixes:
Fixes #130

Special notes for your reviewer:

Release note:

Added metrics named `cert_management_cert_object_expire` for certificate expiration date.
Updated golang builder image from version `1.20.4` to `1.20.5`.

@MartinWeindel MartinWeindel requested a review from a team as a code owner June 13, 2023 11:34
@gardener-robot gardener-robot added needs/review Needs review size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jun 13, 2023
@gardener-robot-ci-3 gardener-robot-ci-3 added the reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) label Jun 13, 2023
@gardener-robot-ci-2 gardener-robot-ci-2 added needs/ok-to-test Needs approval for testing (check PR in detail before setting this label because PR is run on CI/CD) and removed reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) labels Jun 13, 2023
@MartinWeindel MartinWeindel merged commit 6f6d92e into master Jun 13, 2023
@gardener-robot gardener-robot added the status/closed Issue is closed (either delivered or triaged) label Jun 13, 2023
@MartinWeindel MartinWeindel deleted the expire-metrics branch June 13, 2023 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs/ok-to-test Needs approval for testing (check PR in detail before setting this label because PR is run on CI/CD) needs/review Needs review size/S Denotes a PR that changes 10-29 lines, ignoring generated files. status/closed Issue is closed (either delivered or triaged)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enhance the cert-manager certificate metrics
4 participants