1
0
mirror of https://github.com/go-micro/go-micro.git synced 2025-08-10 21:52:01 +02:00

If secure or tlsconfig not nil then secure

This commit is contained in:
Asim
2016-01-17 00:33:07 +00:00
parent 48798027d0
commit a6ce435a07
2 changed files with 18 additions and 8 deletions

View File

@@ -121,7 +121,7 @@ func newConsulRegistry(addrs []string, opts ...Option) Registry {
}
// requires secure connection?
if opt.Secure {
if opt.Secure || opt.TLSConfig != nil {
config.Scheme = "https"
// We're going to support InsecureSkipVerify
config.HttpClient.Transport = newTransport(opt.TLSConfig)