commit a12fe3b5570497d97dd96c25b73b330a0f17a898
parent 6294b4161bc859bf9550e16f437662180c65b432
Author: Henrique Chan Carvalho Machado <henriqueccmachado@tecnico.ulisboa.pt>
Date: Tue, 25 Nov 2025 22:49:23 +0100
oauth2_gateway: fix socket delete on restart
Diffstat:
1 file changed, 0 insertions(+), 5 deletions(-)
diff --git a/oauth2_gateway/src/main.rs b/oauth2_gateway/src/main.rs
@@ -52,11 +52,6 @@ async fn main() -> Result<()> {
if config.server.is_unix_socket() {
let socket_path = config.server.socket_path.as_ref().unwrap();
- if std::path::Path::new(socket_path).exists() {
- tracing::warn!("Removing existing socket file: {}", socket_path);
- std::fs::remove_file(socket_path)?;
- }
-
let listener = tokio::net::UnixListener::bind(socket_path)?;
tracing::info!("Server listening on Unix socket: {}", socket_path);