fix: restore missing comments and TODOs in getters

Signed-off-by: akshat09867 <codingmaster902@gmail.com>
pull/31780/head
akshat09867 8 months ago
parent 86c0c63c72
commit 7eb9ca17b7

@ -133,7 +133,9 @@ func (g *HTTPGetter) httpClient() (*http.Client, error) {
g.transport = &http.Transport{ g.transport = &http.Transport{
DisableCompression: true, DisableCompression: true,
Proxy: http.ProxyFromEnvironment, Proxy: http.ProxyFromEnvironment,
TLSClientConfig: &tls.Config{}, // Being nil would cause the tls.Config default to be used
// "NewTLSConfig" modifies an empty TLS config, not the default one
TLSClientConfig: &tls.Config{},
} }
}) })

@ -108,6 +108,7 @@ func (g *getterPlugin) Get(href string, options ...Option) (*bytes.Buffer, error
env = append(env, "HELM_DEBUG=1") env = append(env, "HELM_DEBUG=1")
} }
// TODO optimization: pass this along to Get() instead of re-parsing here
u, err := url.Parse(href) u, err := url.Parse(href)
if err != nil { if err != nil {
return nil, err return nil, err
@ -120,6 +121,8 @@ func (g *getterPlugin) Get(href string, options ...Option) (*bytes.Buffer, error
Protocol: u.Scheme, Protocol: u.Scheme,
}, },
Env: env, Env: env,
// TODO should we pass Stdin, Stdout, and Stderr through Input here to getter plugins?
// Stdout: os.Stdout,
} }
output, err := g.plg.Invoke(context.Background(), input) output, err := g.plg.Invoke(context.Background(), input)
if err != nil { if err != nil {

Loading…
Cancel
Save