From 794e9d950888f35e0194cad0360f584f5dc21c3d Mon Sep 17 00:00:00 2001 From: Thijs Schreijer Date: Mon, 26 Jun 2023 13:22:25 +0200 Subject: [PATCH 1/2] feat(proxy): honor the proxy environment variables --- utils/types.go | 1 + 1 file changed, 1 insertion(+) diff --git a/utils/types.go b/utils/types.go index a4d377df1..c8c134697 100644 --- a/utils/types.go +++ b/utils/types.go @@ -292,6 +292,7 @@ func GetKonnectClient(httpClient *http.Client, config KonnectConfig) (*konnect.C if httpClient == nil { defaultTransport := http.DefaultTransport.(*http.Transport) + defaultTransport.Proxy = http.ProxyFromEnvironment httpClient = http.DefaultClient httpClient.Transport = defaultTransport } From 3f18be35c0b078c88ed059af13ada7f603863fe8 Mon Sep 17 00:00:00 2001 From: Gabriele Gerbino Date: Wed, 28 Jun 2023 14:36:17 +0200 Subject: [PATCH 2/2] add proxy to http client creation --- utils/types.go | 1 + 1 file changed, 1 insertion(+) diff --git a/utils/types.go b/utils/types.go index c8c134697..04b8f0669 100644 --- a/utils/types.go +++ b/utils/types.go @@ -330,6 +330,7 @@ func HTTPClient() *http.Client { Timeout: clientTimeout, }).DialContext, TLSHandshakeTimeout: clientTimeout, + Proxy: http.ProxyFromEnvironment, }, } }