Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion libdd-common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -348,9 +348,14 @@ impl Endpoint {
pub fn to_reqwest_client_builder(&self) -> anyhow::Result<(reqwest::ClientBuilder, String)> {
use anyhow::Context;

// Don't use proxies, as this calls `getenv` which is unsafe and not
// just in theory. It can cause crashes with PHP where php-fpm's env
// configuration will mutate the system environment (it doesn't pass
// it as part of the SAPI env, it changes the actual system env).
let mut builder = reqwest::Client::builder()
.timeout(std::time::Duration::from_millis(self.timeout_ms))
.hickory_dns(!self.use_system_resolver);
.hickory_dns(!self.use_system_resolver)
.no_proxy();

let request_url = match self.url.scheme_str() {
// HTTP/HTTPS endpoints
Expand Down
Loading