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

flowctl: initialize rustls crypto provider #1692

Merged
merged 1 commit into from
Oct 11, 2024
Merged
Show file tree
Hide file tree
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
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions crates/flowctl/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ postgrest = { workspace = true }
prost = { workspace = true }
reqwest = { workspace = true }
rusqlite = { workspace = true }
rustls = { workspace = true }
rustyline = { workspace = true }
serde = { workspace = true }
serde-transcode = { workspace = true }
Expand Down
6 changes: 6 additions & 0 deletions crates/flowctl/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ use tracing_subscriber::{filter::LevelFilter, EnvFilter};
fn main() -> Result<(), anyhow::Error> {
let cli = flowctl::Cli::parse();

// Required in order for libraries to use `rustls` for TLS.
// See: https://docs.rs/rustls/latest/rustls/crypto/struct.CryptoProvider.html
rustls::crypto::aws_lc_rs::default_provider()
.install_default()
.expect("failed to install default crypto provider");

let env_filter = EnvFilter::builder()
.with_default_directive(LevelFilter::WARN.into()) // Otherwise it's ERROR.
.from_env_lossy();
Expand Down
Loading