mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-30 15:05:27 +00:00
add logging for csr being approved and issued.
This commit is contained in:
parent
d4c5637680
commit
fdd7424d19
@ -115,8 +115,12 @@ func WaitForCertificate(ctx context.Context, client certificatesclient.Certifica
|
||||
if c.Type == certificates.CertificateDenied {
|
||||
return false, fmt.Errorf("certificate signing request is not approved, reason: %v, message: %v", c.Reason, c.Message)
|
||||
}
|
||||
if c.Type == certificates.CertificateApproved && csr.Status.Certificate != nil {
|
||||
return true, nil
|
||||
if c.Type == certificates.CertificateApproved {
|
||||
if csr.Status.Certificate != nil {
|
||||
klog.V(2).Infof("certificate signing request %s is issued", csr.Name)
|
||||
return true, nil
|
||||
}
|
||||
klog.V(2).Infof("certificate signing request %s is approved, waiting to be issued", csr.Name)
|
||||
}
|
||||
}
|
||||
return false, nil
|
||||
|
Loading…
Reference in New Issue
Block a user