From 449240320d505cf27cb0a4f851b558065e0e6a0f Mon Sep 17 00:00:00 2001 From: Cairry <115769353+Cairry@users.noreply.github.com> Date: Wed, 18 Dec 2024 15:46:42 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=B8=20Optimize=20http=20method=20suppo?= =?UTF-8?q?rted=20local=20env=20proxy?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkg/tools/http.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkg/tools/http.go b/pkg/tools/http.go index 3c60838..a53de93 100644 --- a/pkg/tools/http.go +++ b/pkg/tools/http.go @@ -16,6 +16,7 @@ func Get(headers map[string]string, url string, timeout int) (*http.Response, er TLSClientConfig: &tls.Config{ InsecureSkipVerify: true, }, + Proxy: http.ProxyFromEnvironment, } client := http.Client{ @@ -45,6 +46,7 @@ func Post(headers map[string]string, url string, bodyReader *bytes.Reader, timeo TLSClientConfig: &tls.Config{ InsecureSkipVerify: true, }, + Proxy: http.ProxyFromEnvironment, } client := http.Client{