Merge pull request #1490 from fluxcd/fix-1485

helm: Use the default transport pool to preserve proxy settings
This commit is contained in:
souleb 2024-06-14 09:01:56 +02:00 committed by GitHub
commit 09575db5ca
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 3 deletions

View File

@ -69,10 +69,10 @@ func newClient(credentialsFile string, tlsConfig *tls.Config, insecureHTTP bool)
opts = append(opts, registry.ClientOptPlainHTTP())
}
if tlsConfig != nil {
t := http.DefaultTransport.(*http.Transport).Clone()
t.TLSClientConfig = tlsConfig
opts = append(opts, registry.ClientOptHTTPClient(&http.Client{
Transport: &http.Transport{
TLSClientConfig: tlsConfig,
},
Transport: t,
}))
}
if credentialsFile != "" {