mirror of
https://github.com/rancher/rke.git
synced 2025-09-12 13:18:47 +00:00
Run rebuild cluster certs from clusterup
This commit is contained in:
committed by
Alena Prokharchyk
parent
918b4ad669
commit
3c6c7f1b7b
@@ -177,7 +177,8 @@ func RotateRKECertificates(ctx context.Context, c *Cluster, flags ExternalFlags,
|
||||
}
|
||||
}
|
||||
}
|
||||
if len(rotateFlags.Services) == 0 {
|
||||
// to handle kontainer engine sending empty string for services
|
||||
if len(rotateFlags.Services) == 0 || (len(rotateFlags.Services) == 1 && rotateFlags.Services[0] == "") {
|
||||
// do not rotate service account token
|
||||
if c.Certificates[pki.ServiceAccountTokenKeyName].Key != nil {
|
||||
serviceAccountTokenKey = string(cert.EncodePrivateKeyPEM(c.Certificates[pki.ServiceAccountTokenKeyName].Key))
|
||||
|
Reference in New Issue
Block a user