aboutsummaryrefslogtreecommitdiff
path: root/src/api/admin/api_server.rs
diff options
context:
space:
mode:
authornetworkException <git@nwex.de>2023-09-29 18:41:00 +0200
committernetworkException <git@nwex.de>2023-09-29 18:57:44 +0200
commit8ec6a53b35e5bb742640a77ff282f2474c63af54 (patch)
tree4b6a82342cd9ce665d933dc243be7e34ad608f32 /src/api/admin/api_server.rs
parent7353038a64cc53cc01c4ec7f21671d3443177707 (diff)
downloadgarage-8ec6a53b35e5bb742640a77ff282f2474c63af54.tar.gz
garage-8ec6a53b35e5bb742640a77ff282f2474c63af54.zip
everywhere: support unix sockets when binding in various places
this patch implements binding to paths as a unix socket for generic server and web server.
Diffstat (limited to 'src/api/admin/api_server.rs')
-rw-r--r--src/api/admin/api_server.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/api/admin/api_server.rs b/src/api/admin/api_server.rs
index 50c79120..43497bad 100644
--- a/src/api/admin/api_server.rs
+++ b/src/api/admin/api_server.rs
@@ -1,5 +1,4 @@
use std::collections::HashMap;
-use std::net::SocketAddr;
use std::sync::Arc;
use async_trait::async_trait;
@@ -18,6 +17,7 @@ use prometheus::{Encoder, TextEncoder};
use garage_model::garage::Garage;
use garage_rpc::system::ClusterHealthStatus;
use garage_util::error::Error as GarageError;
+use garage_util::socket_address::UnixOrTCPSocketAddress;
use crate::generic_server::*;
@@ -61,7 +61,7 @@ impl AdminApiServer {
pub async fn run(
self,
- bind_addr: SocketAddr,
+ bind_addr: UnixOrTCPSocketAddress,
shutdown_signal: impl Future<Output = ()>,
) -> Result<(), GarageError> {
let region = self.garage.config.s3_api.s3_region.clone();