Skip to content

Commit

Permalink
bug: respect proxy from env when downloading
Browse files Browse the repository at this point in the history
we should respect the proxy env var when downloading files.

Signed-off-by: Ricardo Maraschini <[email protected]>
  • Loading branch information
ricardomaraschini committed Oct 2, 2024
1 parent 3af4695 commit 203dd13
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions internal/http/download.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ func Download(ctx context.Context, url string, target io.Writer, options ...Down
Transport: &http.Transport{
// This is a one-shot HTTP client which should release resources immediately.
DisableKeepAlives: true,
Proxy: http.ProxyFromEnvironment,
},
}
req, err := http.NewRequest("GET", url, nil)
Expand Down

0 comments on commit 203dd13

Please sign in to comment.