From 1c8bab0f04a1c1dd32eba84f8123588c7d5e22bc Mon Sep 17 00:00:00 2001 From: Boban Blaskovic Date: Sun, 31 May 2026 21:01:28 +0200 Subject: [PATCH] nginx: extra_hosts host-gateway for vite HMR upstream; gitignore root .env nginx config has static upstream pointing at host.docker.internal:5173 for Vite dev server. Without extra_hosts the DNS lookup fails at nginx startup and crashes the container. Added back, harmless in prod (upstream just unused). --- .gitignore | 5 +++++ docker-compose.yml | 2 ++ 2 files changed, 7 insertions(+) diff --git a/.gitignore b/.gitignore index 363bc78..35c43a1 100644 --- a/.gitignore +++ b/.gitignore @@ -17,3 +17,8 @@ app/node_modules/ app/vendor/ app/public/build/ app/public/hot + +# Compose stack env (contains secrets) +/.env +/.env.local + diff --git a/docker-compose.yml b/docker-compose.yml index 55fff02..5734525 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -48,6 +48,8 @@ services: restart: unless-stopped ports: - "${HTTP_PORT:-80}:80" + extra_hosts: + - "host.docker.internal:host-gateway" depends_on: app: condition: service_started