From a2b3664e24d8be2c5c93a5c5007159a2c76f02ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=98=D0=BB=D1=8C=D1=8F=20=D0=91=D1=80=D0=B0=D1=82=D1=81?= =?UTF-8?q?=D0=BA=D0=B8=D1=85?= Date: Sun, 1 Nov 2026 18:00:00 +0300 Subject: [PATCH] =?UTF-8?q?feat:=20=D0=B4=D0=BE=D0=B1=D0=B0=D0=B2=D0=B8?= =?UTF-8?q?=D0=BB=20=D1=84=D0=B0=D0=B9=D0=BB=20=D0=BA=D0=BE=D0=BD=D1=84?= =?UTF-8?q?=D0=B8=D0=B3=D1=83=D1=80=D0=B0=D1=86=D0=B8=D0=B8=20=D0=B4=D0=BB?= =?UTF-8?q?=D1=8F=20nginx?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker/nginx.conf | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 docker/nginx.conf diff --git a/docker/nginx.conf b/docker/nginx.conf new file mode 100644 index 0000000..c0933c1 --- /dev/null +++ b/docker/nginx.conf @@ -0,0 +1,28 @@ +worker_processes auto; +error_log /dev/stderr notice; +pid /tmp/nginx.pid; + +events { + worker_connections 1024; +} + +http { + access_log /dev/stdout; + client_body_temp_path /tmp/client_temp; + proxy_temp_path /tmp/proxy_temp; + # Docker DNS. Переменная в proxy_pass заставляет nginx заново резолвить + # имя web, иначе после масштабирования он держит один старый IP. + resolver 127.0.0.11 valid=5s ipv6=off; + + server { + listen 8080; + + location / { + set $web web; + proxy_pass http://$web:3000; + proxy_http_version 1.1; + proxy_set_header Host $host; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + } + } +}