From 39697cd9737980f41dc79f7b205a36f8fb112627 Mon Sep 17 00:00:00 2001
From: jdicioccio <jd@ods.org>
Date: Sat, 25 Jan 2025 00:26:52 -1000
Subject: [PATCH] fix: increase upload timeout (#15588)

Fix upload timeout issue

Fix an issue where when uploading a large file, the upload would consistently abort after 30 minutes. I changed this timeout from 30 minutes to 1 day. Maybe that's excessive, or maybe the timeout isn't even needed, but the current 30 minute timeout definitely seems way too short.
---
 server/src/workers/api.ts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/server/src/workers/api.ts b/server/src/workers/api.ts
index d6dc7233d1..ddf6e50aa2 100644
--- a/server/src/workers/api.ts
+++ b/server/src/workers/api.ts
@@ -62,7 +62,7 @@ async function bootstrap() {
   app.use(app.get(ApiService).ssr(excludePaths));
 
   const server = await (host ? app.listen(port, host) : app.listen(port));
-  server.requestTimeout = 30 * 60 * 1000;
+  server.requestTimeout = 24 * 60 * 60 * 1000;
 
   logger.log(`Immich Server is listening on ${await app.getUrl()} [v${serverVersion}] [${environment}] `);
 }