benchmark: util.go

allow client to setup TLS with cluster members, without the client having to offer TLS authentication itself

fixes #10142
This commit is contained in:
Mark Petrovic 2018-10-02 08:40:01 -07:00
parent 051b119cd3
commit 95a282efb5

View File

@ -96,7 +96,7 @@ func mustCreateConn() *clientv3.Client {
Endpoints: connEndpoints,
DialTimeout: dialTimeout,
}
if !tls.Empty() {
if !tls.Empty() || tls.TrustedCAFile != "" {
cfgtls, err := tls.ClientConfig()
if err != nil {
fmt.Fprintf(os.Stderr, "bad tls config: %v\n", err)