diff options
author | Michal Gebauer <mishak@mishak.net> | 2015-11-19 23:30:29 +0100 |
---|---|---|
committer | Michal Gebauer <mishak@mishak.net> | 2015-11-25 18:12:19 +0100 |
commit | bcd0f0cdc48180307d15c854f75e000b72f12ac8 (patch) | |
tree | 92b01a055db0b36a41c9b5aa1f8dc8cfc57b130c /registry/registry.go | |
parent | 9cbfa7b00bd3b542632b40c5726316923d90cd18 (diff) | |
download | docker-bcd0f0cdc48180307d15c854f75e000b72f12ac8.tar.gz |
Check if CertsDir is not empty
Signed-off-by: Michal Gebauer <mishak@mishak.net>
Diffstat (limited to 'registry/registry.go')
-rw-r--r-- | registry/registry.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/registry/registry.go b/registry/registry.go index 9c8666eaca..6a0587a237 100644 --- a/registry/registry.go +++ b/registry/registry.go @@ -62,7 +62,7 @@ func newTLSConfig(hostname string, isSecure bool) (*tls.Config, error) { tlsConfig.InsecureSkipVerify = !isSecure - if isSecure { + if isSecure && CertsDir != "" { hostDir := filepath.Join(CertsDir, cleanPath(hostname)) logrus.Debugf("hostDir: %s", hostDir) if err := ReadCertsDirectory(&tlsConfig, hostDir); err != nil { |