packer-cn/packer-plugin-sdk/net/default_client.go

15 lines
215 B
Go

package net
import (
"net/http"
)
func HttpClientWithEnvironmentProxy() *http.Client {
httpClient := &http.Client{
Transport: &http.Transport{
Proxy: http.ProxyFromEnvironment,
},
}
return httpClient
}