From 6f5491098697d0fb94de948c873da41b1507bd54 Mon Sep 17 00:00:00 2001 From: Nicholas Gerrer Date: Wed, 25 Feb 2026 23:34:56 -0500 Subject: [PATCH] fix: add configurable uwsgi_read_timeout to fix 504 timeout on large M3U imports (fixes #745) --- docker/entrypoint.sh | 1 + docker/init/03-init-dispatcharr.sh | 1 + docker/nginx.conf | 1 + 3 files changed, 3 insertions(+) diff --git a/docker/entrypoint.sh b/docker/entrypoint.sh index b79af952..dc36421a 100755 --- a/docker/entrypoint.sh +++ b/docker/entrypoint.sh @@ -41,6 +41,7 @@ export REDIS_DB=${REDIS_DB:-0} export REDIS_PASSWORD=${REDIS_PASSWORD:-} export REDIS_USER=${REDIS_USER:-} export DISPATCHARR_PORT=${DISPATCHARR_PORT:-9191} +export NGINX_UWSGI_TIMEOUT=${NGINX_UWSGI_TIMEOUT:-300} export LIBVA_DRIVERS_PATH='/usr/local/lib/x86_64-linux-gnu/dri' export LD_LIBRARY_PATH='/usr/local/lib' export SECRET_FILE="/data/jwt" diff --git a/docker/init/03-init-dispatcharr.sh b/docker/init/03-init-dispatcharr.sh index 0c317017..186831ea 100644 --- a/docker/init/03-init-dispatcharr.sh +++ b/docker/init/03-init-dispatcharr.sh @@ -36,6 +36,7 @@ if ! [[ "$DISPATCHARR_PORT" =~ ^[0-9]+$ ]]; then DISPATCHARR_PORT=9191 fi sed -i "s/NGINX_PORT/${DISPATCHARR_PORT}/g" /etc/nginx/sites-enabled/default +sed -i "s/NGINX_UWSGI_TIMEOUT/${NGINX_UWSGI_TIMEOUT}/g" /etc/nginx/sites-enabled/default # Configure nginx based on IPv6 availability if ip -6 addr show | grep -q "inet6"; then diff --git a/docker/nginx.conf b/docker/nginx.conf index e08d08f2..c8ee3bc1 100644 --- a/docker/nginx.conf +++ b/docker/nginx.conf @@ -21,6 +21,7 @@ server { location / { include uwsgi_params; uwsgi_pass unix:/app/uwsgi.sock; + uwsgi_read_timeout NGINX_UWSGI_TIMEOUT; } location /assets/ {