added support to read proxy settings from env vars#2571
added support to read proxy settings from env vars#2571chris-gunawardena wants to merge 2 commits intoelastic:mainfrom
Conversation
|
❌ Author of the following commits did not sign a Contributor Agreement: Please, read and sign the above mentioned agreement if you want to contribute to this project |
|
@chris-gunawardena thanks for the contribution! I think this is a good change to add to Connectors. There are a few things we need to work on before merging first.
|
We also need to add proxy support between the Connector and the Elasticsearch endpoint. |
I think that's why @navarone-feekery asked to change the PR description from |
|
buildkite test this |
part of #2017
This solves the issue of the connectors ignoring system proxy settings in env vars.
Added trust_env=True according to https://docs.aiohttp.org/en/stable/client_advanced.html#aiohttp-client-proxy-support
The use of proxy is needed when running the connector alongside elastic cluster behind a corporate firewall, a proxy is used to expose outgoing traffic. For example, to externally SaaS products like ServiceNow, Sharepoint intranet, Teams and Confluence
Checklists
Pre-Review Checklist
config.yml.example)v7.13.2,v7.14.0,v8.0.0)Changes Requiring Extra Attention
Related Pull Requests
#2266
Work around
In case this doesn't go through, it's possible to do this in the docker build with
RUN sed -i 's/aiohttp.ClientSession(/aiohttp.ClientSession(trust_env=True,/g' /app/connectors/sources/sharepoint_online.py