// if there are no authentication credentials (nor in the config returned from discovery, nor in the TLSBootstrapToken), fail
// if there are no authentication credentials (nor in the config returned from discovery, nor in the TLSBootstrapToken), fail
returnnil,errors.New("couldn't find authentication credentials for the TLS boostrap process. Please use Token discovery, a discovery file with embedded authentication credentials or a discovery file without authentication credentials and the TLSBootstrapToken flag")
returnnil,errors.New("couldn't find authentication credentials for the TLS boostrap process. Please use Token discovery, a discovery file with embedded authentication credentials or a discovery file without authentication credentials but with the TLSBootstrapToken flag")
}
}
// DiscoverValidatedKubeConfig returns a validated Config object that specifies where the cluster is and the CA cert to trust
// DiscoverValidatedKubeConfig returns a validated Config object that specifies where the cluster is and the CA cert to trust
klog.Warningf("[discovery] Could not access the %s ConfigMap for refreshing the cluster-info information, but the TLS cert is valid so proceeding...\n",bootstrapapi.ConfigMapClusterInfo)
klog.Warningf("[discovery] Could not access the %s ConfigMap for refreshing the cluster-info information, but the TLS cert is valid so proceeding...\n",bootstrapapi.ConfigMapClusterInfo)
returntrue,nil
returntrue,nil
}
}
klog.V(1).Infof("[discovery] Error reading the %s ConfigMap, will try again: [%v]\n",bootstrapapi.ConfigMapClusterInfo,err)
klog.V(1).Infof("[discovery] Error reading the %s ConfigMap, will try again: %v\n",bootstrapapi.ConfigMapClusterInfo,err)