fix(dev): share auth across dev frontend proxy

This commit is contained in:
Codex
2026-05-19 04:41:28 +00:00
parent dfb344ef0c
commit 0c833a7be2
9 changed files with 184 additions and 22 deletions
@@ -5,6 +5,29 @@ server {
# The dev frontend is intentionally reached through the existing backend-core
# microservice proxy so the public port does not need direct access to D601.
# Auth endpoints use the production frontend only to issue/clear the shared
# host-scoped UniDesk session cookie. Application routes and APIs still go to
# frontend-dev.
location = /login {
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Real-IP $remote_addr;
proxy_pass http://frontend:8080$request_uri;
}
location = /logout {
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Real-IP $remote_addr;
proxy_pass http://frontend:8080$request_uri;
}
location / {
proxy_http_version 1.1;
proxy_set_header Host $host;