Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TT-12174 Added support for proxy settings loaded from environment variables #394

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

codingWombat
Copy link

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.

Related Issue

#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

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Refactoring or add test (improvements in base code or adds test coverage to functionality)

Checklist

  • Make sure you are requesting to pull a topic/feature/bugfix branch (right side). If pulling from your own
    fork, don't request your master!
  • Make sure you are making a pull request against the master branch (left side). Also, you should start
    your branch off our latest master.
  • My change requires a change to the documentation.
    • If you've changed APIs, describe what needs to be updated in the documentation.
    • If new config option added, ensure that it can be set via ENV variable
  • I have updated the documentation accordingly.
  • Modules and vendor dependencies have been updated; run go mod tidy && go mod vendor
  • When updating library version must provide reason/explanation for this update.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • Check your code additions will not fail linting checks:
    • go fmt -s
    • go vet

@caroltyk caroltyk changed the title Added support for proxy settings loaded from environment variables TT-12174 Added support for proxy settings loaded from environment variables May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant