generated from 18F/open-source-policy
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Document some known gotchas in both ruby and python apps
- Loading branch information
Showing
3 changed files
with
24 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Using cg-egress-proxy with a Python application | ||
|
||
## SSL Certificate errors | ||
|
||
It has been found that several Environment variables need to be set for various networking libraries to load the SSL certificate used to protect the TLS connection between the application and the proxy. The following variables have been used: | ||
|
||
* `REQUESTS_CA_BUNDLE` for the [requests](https://pypi.org/project/requests/) python library. | ||
* `NEW_RELIC_CA_BUNDLE_PATH` for the [New Relic](https://pypi.org/project/newrelic/) SDK. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Using cg-egress-proxy with a Ruby application | ||
|
||
By default,[^1] `net/http` proxy support is limited to connecting to `http` proxies, and not `https` proxies. To make proxied connections in Ruby, use [Faraday](https://rubygems.org/gems/faraday) along with one of the following two adapters[^2]: | ||
|
||
* [faraday-typhoeus](https://rubygems.org/gems/faraday-typhoeus) | ||
* [faraday-patron](https://rubygems.org/gems/faraday-patron) | ||
|
||
Both of those adapters should work out-of-the-box to configure themselves properly from the `http_proxy` and `https_proxy` environment variables and system certificate store. | ||
|
||
[^1]: As of September 30, 2024 | ||
[^2]: Please update this list if you find more adapters that work. This is not exhaustive. |