Rename employee-tracking-backend to purenotify_backend and add OFFLINE
mode - Rename crate and update dependencies to newer versions - Add OFFLINE runtime mode for loopback-only server without DB - Refactor state handling with typed Axum routers and state injection - Rename mongodb module to mongo and fix imports accordingly - Update Cargo.lock with updated and removed dependencies - Remove no-auth feature and related code - Simplify health and user routes to generic state parameter Rename backend to purenotify_backend and add OFFLINE mode Use OFFLINE env var to run server without DB, binding to loopback only. Rename mongodb module to mongo and update dependencies. Update dependencies and fix router state handling.
This commit is contained in:
@@ -4,7 +4,6 @@ use std::env;
|
||||
use std::net::SocketAddr;
|
||||
use std::str::FromStr;
|
||||
|
||||
#[cfg(feature = "no-auth")]
|
||||
use tracing::error;
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
@@ -22,7 +21,6 @@ impl Config {
|
||||
let bind_address = SocketAddr::from_str(&bind_address_str)
|
||||
.map_err(|e| format!("Invalid BIND_ADDRESS: {}", e))?;
|
||||
|
||||
#[cfg(feature = "no-auth")]
|
||||
if bind_address.ip() != std::net::IpAddr::from([127, 0, 0, 1]) {
|
||||
error!("In no-auth mode, BIND_ADDRESS must be 127.0.0.1");
|
||||
return Err("In no-auth mode, BIND_ADDRESS must be 127.0.0.1".to_string());
|
||||
|
||||
Reference in New Issue
Block a user