From 62446f25974647477b4c3c8f75eb5c9550805140 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9F=D0=B5=D1=80=D0=B2=D0=BE=D0=B2=20=D0=90=D1=80=D1=82?= =?UTF-8?q?=D0=B5=D0=BC?= Date: Mon, 20 Apr 2026 23:35:45 +0300 Subject: [PATCH] Update Nginx configuration to use a unique backend hostname for API routing to prevent intermittent routing issues --- client/nginx/default.conf | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/client/nginx/default.conf b/client/nginx/default.conf index 7651bae..1067eee 100644 --- a/client/nginx/default.conf +++ b/client/nginx/default.conf @@ -13,7 +13,11 @@ server { } location /api/ { - set $backend http://server:3000; + # Use a globally-unique hostname across attached Docker networks. + # `client` is connected to both `toir-light` and external `proxy` networks, + # so a generic name like `server` can resolve to multiple containers and + # cause intermittent routing (200/404 flapping). + set $backend http://toir-light-server:3000; proxy_pass $backend; proxy_http_version 1.1; proxy_set_header Host $host;