Skip to content

Commit

Permalink
Allow tlsCfg.InsecureSkipVerify outside of mTLS
Browse files Browse the repository at this point in the history
Fix a bug where the `tlsCfg.InsecureSkipVerify` flag was only consumed when using mTLS.

Signed-off-by: GitHub <noreply@github.com>
  • Loading branch information
jfach authored May 20, 2022
1 parent 5609e31 commit 0916b2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mysqld_exporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,8 @@ func customizeTLS(sslCA string, sslCert string, sslKey string) error {
}
certPairs = append(certPairs, keypair)
tlsCfg.Certificates = certPairs
tlsCfg.InsecureSkipVerify = *tlsInsecureSkipVerify
}
tlsCfg.InsecureSkipVerify = *tlsInsecureSkipVerify
mysql.RegisterTLSConfig("custom", &tlsCfg)
return nil
}
Expand Down

0 comments on commit 0916b2c

Please sign in to comment.