This is an automated email from the ASF dual-hosted git repository.
tustvold pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow-rs.git
The following commit(s) were added to refs/heads/master by this push:
new 9b590819b Allow Configuring non-TLS HTTP Connections in
AmazonS3Builder::from_env (#2807)
9b590819b is described below
commit 9b590819baffb117383dfd026f92987f4f9f6950
Author: Brent Gardner <[email protected]>
AuthorDate: Mon Oct 3 05:52:38 2022 -0700
Allow Configuring non-TLS HTTP Connections in AmazonS3Builder::from_env
(#2807)
* Allow HTTP
* Update docs
---
object_store/src/aws/mod.rs | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/object_store/src/aws/mod.rs b/object_store/src/aws/mod.rs
index e3510b3e2..c08a6353f 100644
--- a/object_store/src/aws/mod.rs
+++ b/object_store/src/aws/mod.rs
@@ -376,6 +376,7 @@ impl AmazonS3Builder {
/// * AWS_ENDPOINT -> endpoint
/// * AWS_SESSION_TOKEN -> token
/// * AWS_CONTAINER_CREDENTIALS_RELATIVE_URI ->
<https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html>
+ /// * AWS_ALLOW_HTTP -> set to "true" to permit HTTP connections without
TLS
/// # Example
/// ```
/// use object_store::aws::AmazonS3Builder;
@@ -416,6 +417,10 @@ impl AmazonS3Builder {
Some(format!("{}{}", METADATA_ENDPOINT,
metadata_relative_uri));
}
+ if let Ok(text) = std::env::var("AWS_ALLOW_HTTP") {
+ builder.allow_http = text == "true";
+ }
+
builder
}