Fix race in healthchecking etcds leading to crashes

This commit is contained in:
Wojciech Tyczynski 2018-02-20 12:17:39 +01:00
parent e267f46c8e
commit 38387aec0d

View File

@ -321,8 +321,10 @@ func (s *DefaultStorageFactory) Backends() []Backend {
backends := []Backend{}
for server := range servers {
backends = append(backends, Backend{
Server: server,
TLSConfig: tlsConfig,
Server: server,
// We can't share TLSConfig across different backends to avoid races.
// For more details see: http://pr.k8s.io/59338
TLSConfig: tlsConfig.Clone(),
})
}
return backends