Fix DNS conflict by using unique container names

- Add container_name for backend and frontend services
- Update nginx proxy to use veridian-preview-backend hostname
- Fixes issue where DNS was resolving to wrong backend container

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
fullsizemalt 2026-01-08 20:37:54 -08:00
parent 4894679357
commit 7a19798c48
2 changed files with 3 additions and 1 deletions

View file

@ -30,6 +30,7 @@ services:
retries: 5 retries: 5
backend: backend:
container_name: veridian-preview-backend
build: build:
context: ./backend context: ./backend
dockerfile: Dockerfile dockerfile: Dockerfile
@ -93,6 +94,7 @@ services:
- go2rtc - go2rtc
frontend: frontend:
container_name: veridian-preview-frontend
build: build:
context: ./frontend context: ./frontend
dockerfile: Dockerfile dockerfile: Dockerfile

View file

@ -6,7 +6,7 @@ server {
# API proxy # API proxy
location /api { location /api {
proxy_pass http://backend:3000; proxy_pass http://veridian-preview-backend:3000;
proxy_http_version 1.1; proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade; proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade'; proxy_set_header Connection 'upgrade';