aboutsummaryrefslogtreecommitdiffstats
path: root/crates/server/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--crates/server/src/lib.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/crates/server/src/lib.rs b/crates/server/src/lib.rs
index a4b10acf..726afeea 100644
--- a/crates/server/src/lib.rs
+++ b/crates/server/src/lib.rs
@@ -5,14 +5,14 @@ use axum::{Router, serve};
use database::db::ServerPostgres;
use eyre::{Context, Result};
-pub(crate) mod database;
+pub mod database;
mod handlers;
mod metrics;
mod router;
-pub(crate) use settings::Settings;
+pub use settings::Settings;
-pub(crate) mod settings;
+pub mod settings;
use tokio::net::TcpListener;
use tokio::signal;
@@ -31,7 +31,7 @@ async fn shutdown_signal() {
eprintln!("Shutting down gracefully...");
}
-pub(crate) async fn launch(settings: Settings, addr: SocketAddr) -> Result<()> {
+pub async fn launch(settings: Settings, addr: SocketAddr) -> Result<()> {
launch_with_tcp_listener(
settings,
TcpListener::bind(addr)
@@ -42,7 +42,7 @@ pub(crate) async fn launch(settings: Settings, addr: SocketAddr) -> Result<()> {
.await
}
-pub(crate) async fn launch_with_tcp_listener(
+pub async fn launch_with_tcp_listener(
settings: Settings,
listener: TcpListener,
shutdown: impl Future<Output = ()> + Send + 'static,
@@ -58,7 +58,7 @@ pub(crate) async fn launch_with_tcp_listener(
// The separate listener means it's much easier to ensure metrics are not accidentally exposed to
// the public.
-pub(crate) async fn launch_metrics_server(host: String, port: u16) -> Result<()> {
+pub async fn launch_metrics_server(host: String, port: u16) -> Result<()> {
let listener = TcpListener::bind((host, port))
.await
.context("failed to bind metrics tcp")?;