1
0
mirror of https://github.com/rancher/rke.git synced 2025-09-01 15:06:23 +00:00

Add per node kubelet server certificate

This commit is contained in:
Sebastiaan van Steenis
2019-07-24 22:25:14 +02:00
committed by Alena Prokharchyk
parent fd237d9eef
commit b860e634db
12 changed files with 210 additions and 113 deletions

View File

@@ -168,10 +168,12 @@ func validateIngressOptions(c *Cluster) error {
func ValidateHostCount(c *Cluster) error {
if len(c.EtcdHosts) == 0 && len(c.Services.Etcd.ExternalURLs) == 0 {
failedEtcdHosts := []string{}
for _, host := range c.InactiveHosts {
if host.IsEtcd {
failedEtcdHosts = append(failedEtcdHosts, host.Address)
if len(c.InactiveHosts) > 0 {
failedEtcdHosts := []string{}
for _, host := range c.InactiveHosts {
if host.IsEtcd {
failedEtcdHosts = append(failedEtcdHosts, host.Address)
}
}
return fmt.Errorf("Cluster must have at least one etcd plane host: failed to connect to the following etcd host(s) %v", failedEtcdHosts)
}