소스 검색

server: fix proxy not being set from environment on ollama pull and ollama push

jmorganca 5 달 전
부모
커밋
bc40a820f0
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      server/images.go

+ 1 - 0
server/images.go

@@ -1078,6 +1078,7 @@ func makeRequest(ctx context.Context, method string, requestURL *url.URL, header
 
 	resp, err := (&http.Client{
 		Transport: &http.Transport{
+			Proxy:       http.ProxyFromEnvironment,
 			DialContext: testMakeRequestDialContext,
 		},
 		CheckRedirect: regOpts.CheckRedirect,