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

Implement parsing of certificate validity duration and renewal grace period from service labels #9

Open
simu opened this issue Oct 12, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@simu
Copy link
Member

simu commented Oct 12, 2022

Currently, both the certificate validity duration and the renewal grace period are hard-coded in the controller. We should implement optional service labels which users can set to customize the validity duration and renewal grace period for their service certificates.

Current implementation:

func certDurationFromSvc(svc *corev1.Service) (*metav1.Duration, error) {
// TODO: annotation/label on svc
d, err := time.ParseDuration("2160h")
if err != nil {
return nil, err
}
return &metav1.Duration{Duration: d}, nil
}
func certRenewBeforeFromSvc(svc *corev1.Service) (*metav1.Duration, error) {
// TODO: annotation/label on svc
d, err := time.ParseDuration("360h")
if err != nil {
return nil, err
}
return &metav1.Duration{Duration: d}, nil
}

@simu simu added the enhancement New feature or request label Oct 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant