diff --git a/ui/nginx.conf b/ui/nginx.conf index a50c4c1..80723ea 100644 --- a/ui/nginx.conf +++ b/ui/nginx.conf @@ -5,6 +5,10 @@ server { # Allow large request bodies (screenshots are base64 encoded) client_max_body_size 50M; + # Use Docker's internal DNS resolver — resolves upstream at request time, not startup + resolver 127.0.0.11 valid=30s; + set $backend http://master:9090; + # Serve static files from the React build location / { root /usr/share/nginx/html; @@ -14,8 +18,8 @@ server { # Reverse proxy API requests to the Master backend container location /api/ { - proxy_pass http://master:9090; - + proxy_pass $backend; + # Standard proxy headers proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr;