Added http.ProxyFromEnvironment to creation of transport for the default client.
Description
In the main.go file the transport of the http.DefaultClient is overwritten because InsecureSkipVerify: config.SSLInsecureSkipVerify is added. This disables the default behavior of go that the environment variables HTTP_PROXY, HTTPS_PROXY and NO_PROXY are used for HTTP connections.
Added
http.ProxyFromEnvironment
to creation of transport for the default client.Description
In the main.go file the
transport
of thehttp.DefaultClient
is overwritten becauseInsecureSkipVerify: config.SSLInsecureSkipVerify
is added. This disables the default behavior of go that the environment variablesHTTP_PROXY
,HTTPS_PROXY
andNO_PROXY
are used for HTTP connections.Related Issue
https://github.com/TykTechnologies/tyk-identity-broker/issues/393
Motivation and Context
The change allows to use the tyk identity broker to be used in environments where access to external services is managed by a http porxy.
How This Has Been Tested
Patched image used to gain access to a identiy provider via HTTP Proxy
Types of changes
Checklist
master
!master
branch (left side). Also, you should start your branch off our latestmaster
.go mod tidy && go mod vendor
go fmt -s
go vet