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 expiring certificates and use common prefix for metric names #58

Merged
merged 2 commits into from
Dec 21, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -511,6 +511,7 @@ Flags:
--dns-owner-id string ownerId for creating challenge DNSEntries
--dns.disable-deploy-crds disable deployment of required crds for cluster dns
--dns.id string id for cluster dns
--dns.migration-ids string migration id for cluster dns
--force-crd-update enforce update of crds even they are unmanaged
--grace-period duration inactivity grace period for detecting end of cleanup for shutdown
-h, --help help for cert-controller-manager
Expand Down Expand Up @@ -541,12 +542,14 @@ Flags:
--issuer.precheck-additional-wait duration additional wait time after DNS propagation check of controller issuer (default 10s)
--issuer.precheck-nameservers string DNS nameservers used for checking DNS propagation. If explicity set empty, it is tried to read them from /etc/resolv.conf of controller issuer (default "8.8.8.8:53,8.8.4.4:53")
--issuer.propagation-timeout duration propagation timeout for DNS challenge of controller issuer (default 1m0s)
--issuer.renewal-overdue-window duration certificate is counted as 'renewal overdue' if its validity period is shorter (metrics cert_management_overdue_renewal_certificates) of controller issuer (default 600h0m0s)
--issuer.renewal-window duration certificate is renewed if its validity period is shorter of controller issuer (default 720h0m0s)
--issuer.secrets.pool.size int Worker pool size for pool secrets of controller issuer (default 1)
--issuers.pool.size int Worker pool size for pool issuers
--kubeconfig string default cluster access
--kubeconfig.disable-deploy-crds disable deployment of required crds for cluster default
--kubeconfig.id string id for cluster default
--kubeconfig.migration-ids string migration id for cluster default
--lease-duration duration lease duration (default 15s)
--lease-name string name for lease object
--lease-renew-deadline duration lease renew deadline (default 10s)
Expand All @@ -563,6 +566,7 @@ Flags:
--precheck-additional-wait duration additional wait time after DNS propagation check
--precheck-nameservers string DNS nameservers used for checking DNS propagation. If explicity set empty, it is tried to read them from /etc/resolv.conf
--propagation-timeout duration propagation timeout for DNS challenge
--renewal-overdue-window duration certificate is counted as 'renewal overdue' if its validity period is shorter (metrics cert_management_overdue_renewal_certificates)
--renewal-window duration certificate is renewed if its validity period is shorter
--secrets.pool.size int Worker pool size for pool secrets
--server-port-http int HTTP server port (serving /healthz, /metrics, ...)
Expand All @@ -578,11 +582,13 @@ Flags:
--source string source cluster to watch for ingresses and services
--source.disable-deploy-crds disable deployment of required crds for cluster source
--source.id string id for cluster source
--source.migration-ids string migration id for cluster source
--target string target cluster for certificates
--target-name-prefix string name prefix in target namespace for cross cluster generation
--target-namespace string target namespace for cross cluster generation
--target.disable-deploy-crds disable deployment of required crds for cluster target
--target.id string id for cluster target
--target.migration-ids string migration id for cluster target
--targets.pool.size int Worker pool size for pool targets
-v, --version version for cert-controller-manager
```
Expand Down
24 changes: 24 additions & 0 deletions charts/cert-management/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ spec:
args:
- --name={{ include "cert-management.fullname" . }}
### start generated configuration
{{- if .Values.configuration.acceptedMaintainers }}
- --accepted-maintainers={{ .Values.configuration.acceptedMaintainers }}
{{- end }}
{{- if .Values.configuration.bindAddressHttp }}
- --bind-address-http={{ .Values.configuration.bindAddressHttp }}
{{- end }}
Expand Down Expand Up @@ -91,6 +94,12 @@ spec:
{{- if .Values.configuration.dnsId }}
- --dns.id={{ .Values.configuration.dnsId }}
{{- end }}
{{- if .Values.configuration.dnsMigrationIds }}
- --dns.migration-ids={{ .Values.configuration.dnsMigrationIds }}
{{- end }}
{{- if .Values.configuration.forceCrdUpdate }}
- --force-crd-update={{ .Values.configuration.forceCrdUpdate }}
{{- end }}
{{- if .Values.configuration.gracePeriod }}
- --grace-period={{ .Values.configuration.gracePeriod }}
{{- end }}
Expand Down Expand Up @@ -175,6 +184,9 @@ spec:
{{- if .Values.configuration.issuerPropagationTimeout }}
- --issuer.propagation-timeout={{ .Values.configuration.issuerPropagationTimeout }}
{{- end }}
{{- if .Values.configuration.issuerRenewalOverdueWindow }}
- --issuer.renewal-overdue-window={{ .Values.configuration.issuerRenewalOverdueWindow }}
{{- end }}
{{- if .Values.configuration.issuerRenewalWindow }}
- --issuer.renewal-window={{ .Values.configuration.issuerRenewalWindow }}
{{- end }}
Expand All @@ -193,6 +205,9 @@ spec:
{{- if .Values.configuration.kubeconfigId }}
- --kubeconfig.id={{ .Values.configuration.kubeconfigId }}
{{- end }}
{{- if .Values.configuration.kubeconfigMigrationIds }}
- --kubeconfig.migration-ids={{ .Values.configuration.kubeconfigMigrationIds }}
{{- end }}
{{- if .Values.configuration.leaseDuration }}
- --lease-duration={{ .Values.configuration.leaseDuration }}
{{- end }}
Expand Down Expand Up @@ -238,6 +253,9 @@ spec:
{{- if .Values.configuration.propagationTimeout }}
- --propagation-timeout={{ .Values.configuration.propagationTimeout }}
{{- end }}
{{- if .Values.configuration.renewalOverdueWindow }}
- --renewal-overdue-window={{ .Values.configuration.renewalOverdueWindow }}
{{- end }}
{{- if .Values.configuration.renewalWindow }}
- --renewal-window={{ .Values.configuration.renewalWindow }}
{{- end }}
Expand Down Expand Up @@ -283,6 +301,9 @@ spec:
{{- if .Values.configuration.sourceId }}
- --source.id={{ .Values.configuration.sourceId }}
{{- end }}
{{- if .Values.configuration.sourceMigrationIds }}
- --source.migration-ids={{ .Values.configuration.sourceMigrationIds }}
{{- end }}
{{- if .Values.configuration.target }}
- --target={{ .Values.configuration.target }}
{{- end }}
Expand All @@ -298,6 +319,9 @@ spec:
{{- if .Values.configuration.targetId }}
- --target.id={{ .Values.configuration.targetId }}
{{- end }}
{{- if .Values.configuration.targetMigrationIds }}
- --target.migration-ids={{ .Values.configuration.targetMigrationIds }}
{{- end }}
{{- if .Values.configuration.targetsPoolSize }}
- --targets.pool.size={{ .Values.configuration.targetsPoolSize }}
{{- end }}
Expand Down
8 changes: 8 additions & 0 deletions charts/cert-management/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ createCRDs:
certificates: true

configuration:
# acceptedMaintainers:
# bindAddressHttp:
# cascadeDelete:
# certClass:
Expand All @@ -49,6 +50,8 @@ configuration:
# dnsOwnerId:
# dnsDisableDeployCrds:
# dnsId:
# dnsMigrationIds:
# forceCrdUpdate:
# gracePeriod:
# ingressCertCertClass:
# ingressCertCertTargetClass:
Expand Down Expand Up @@ -77,12 +80,14 @@ configuration:
# issuerPrecheckAdditionalWait:
# issuerPrecheckNameservers:
# issuerPropagationTimeout:
# issuerRenewalOverdueWindow:
# issuerRenewalWindow:
# issuerSecretsPoolSize:
# issuersPoolSize:
# kubeconfig:
# kubeconfigDisableDeployCrds:
# kubeconfigId:
# kubeconfigMigrationIds:
# leaseDuration:
# leaseName:
# leaseRenewDeadline:
Expand All @@ -98,6 +103,7 @@ configuration:
# precheckAdditionalWait:
# precheckNameservers:
# propagationTimeout:
# renewalOverdueWindow:
# renewalWindow:
# secretsPoolSize:
serverPortHttp: 8080
Expand All @@ -113,11 +119,13 @@ configuration:
# source:
# sourceDisableDeployCrds:
# sourceId:
# sourceMigrationIds:
# target:
# targetNamePrefix:
# targetNamespace:
# targetDisableDeployCrds:
# targetId:
# targetMigrationIds:
# targetsPoolSize:
# version:

Expand Down
Loading