From fa3ceab30e7563e68467c7b556eec52ed65e9248 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Thu, 10 Apr 2025 10:15:37 +0000 Subject: [PATCH] Fix formatting issues Co-Authored-By: John Spray --- pageserver/src/bin/pageserver.rs | 10 +++++++--- safekeeper/src/bin/safekeeper.rs | 6 ++++-- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/pageserver/src/bin/pageserver.rs b/pageserver/src/bin/pageserver.rs index 32df0d8e0d..d4bd465991 100644 --- a/pageserver/src/bin/pageserver.rs +++ b/pageserver/src/bin/pageserver.rs @@ -102,10 +102,14 @@ fn main() -> anyhow::Result<()> { let (conf, ignored) = initialize_config(&identity_file_path, &cfg_file_path, &workdir)?; if !dev_mode { - if matches!(conf.http_auth_type, AuthType::Trust) || matches!(conf.pg_auth_type, AuthType::Trust) { - bail!("Pageserver refuses to start with HTTP or PostgreSQL API authentication disabled.\n\ + if matches!(conf.http_auth_type, AuthType::Trust) + || matches!(conf.pg_auth_type, AuthType::Trust) + { + bail!( + "Pageserver refuses to start with HTTP or PostgreSQL API authentication disabled.\n\ Run with --dev to allow running without authentication.\n\ - This is insecure and should only be used in development environments."); + This is insecure and should only be used in development environments." + ); } } else { warn!("Starting in dev mode: this may be an insecure configuration."); diff --git a/safekeeper/src/bin/safekeeper.rs b/safekeeper/src/bin/safekeeper.rs index 39b6ebd0b7..fb8f7b0c48 100644 --- a/safekeeper/src/bin/safekeeper.rs +++ b/safekeeper/src/bin/safekeeper.rs @@ -350,9 +350,11 @@ async fn main() -> anyhow::Result<()> { let http_auth_enabled = args.http_auth_public_key_path.is_some(); let pg_auth_enabled = args.pg_auth_public_key_path.is_some(); if !http_auth_enabled || !pg_auth_enabled { - bail!("Safekeeper refuses to start with HTTP or PostgreSQL API authentication disabled.\n\ + bail!( + "Safekeeper refuses to start with HTTP or PostgreSQL API authentication disabled.\n\ Run with --dev to allow running without authentication.\n\ - This is insecure and should only be used in development environments."); + This is insecure and should only be used in development environments." + ); } } else { warn!("Starting in dev mode: this may be an insecure configuration.");