summaryrefslogtreecommitdiffstats
path: root/Cargo.lock
diff options
context:
space:
mode:
authorEric Hodel <drbrain@segment7.net>2023-12-27 06:15:48 -0800
committerGitHub <noreply@github.com>2023-12-27 14:15:48 +0000
commitd52e57612942cbe0c6a0dd774fcc2caac8f439d5 (patch)
tree6abc226ffa71156b0ac747529e7effaa21c75c15 /Cargo.lock
parent86f50e0356e4b661be43c2aeba97a67d83910095 (diff)
feat: Add TLS to atuin-server (#1457)
* Add TLS to atuin-server atuin as a project already includes most of the dependencies necessary for server-side TLS. This allows `atuin server start` to use a TLS certificate when self-hosting in order to avoid the complication of wrapping it in a TLS-aware proxy server. Configuration is handled similar to the metrics server with its own struct and currently accepts only the private key and certificate file paths. Starting a TLS server and a TCP server are divergent because the tests need to bind to an arbitrary port to avoid collisions across tests. The API to accomplish this for a TLS server is much more verbose. * Fix clippy, fmt * Add TLS section to self-hosting
Diffstat (limited to 'Cargo.lock')
-rw-r--r--Cargo.lock33
1 files changed, 33 insertions, 0 deletions
diff --git a/Cargo.lock b/Cargo.lock
index f84e25c1e..440f30242 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -110,6 +110,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6"
[[package]]
+name = "arc-swap"
+version = "1.6.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bddcadddf5e9015d310179a59bb28c4d4b9920ad0f11e8e14dbadf654890c9a6"
+
+[[package]]
name = "argon2"
version = "0.5.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -269,15 +275,20 @@ dependencies = [
"atuin-common",
"atuin-server-database",
"axum",
+ "axum-server",
"base64 0.21.5",
"config",
"eyre",
"fs-err",
"http",
+ "hyper",
+ "hyper-rustls",
"metrics",
"metrics-exporter-prometheus",
"rand",
"reqwest",
+ "rustls",
+ "rustls-pemfile",
"semver",
"serde",
"serde_json",
@@ -373,6 +384,26 @@ dependencies = [
]
[[package]]
+name = "axum-server"
+version = "0.5.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "447f28c85900215cc1bea282f32d4a2f22d55c5a300afdfbc661c8d6a632e063"
+dependencies = [
+ "arc-swap",
+ "bytes",
+ "futures-util",
+ "http",
+ "http-body",
+ "hyper",
+ "pin-project-lite",
+ "rustls",
+ "rustls-pemfile",
+ "tokio",
+ "tokio-rustls",
+ "tower-service",
+]
+
+[[package]]
name = "backtrace"
version = "0.3.69"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -1445,7 +1476,9 @@ dependencies = [
"futures-util",
"http",
"hyper",
+ "log",
"rustls",
+ "rustls-native-certs",
"tokio",
"tokio-rustls",
]