Files
doormilebuild/nginx.conf
Aravind a9f15dd25e fix: run container on port 80 to match Dokploy domain routing (fixes 502)
Dokploy domains were configured to route to internal port 80, but the
Node standalone server listened on 3000, causing Bad Gateway. Align
the container's PORT/EXPOSE with Dokploy's routing instead.
2026-07-14 11:24:54 +05:30

35 lines
1.0 KiB
Nginx Configuration File

# This nginx.conf is NOT used by the Dockerfile (which runs Node.js directly).
# It is kept here as a reference in case you add an Nginx reverse proxy layer
# in front of the Node.js container (e.g., on the host or in Dokploy).
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
upstream nextjs {
server 127.0.0.1:80;
}
server {
listen 80;
server_name doormile.com www.doormile.com;
# Proxy all requests to the Next.js standalone server
location / {
proxy_pass http://nextjs;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_cache_bypass $http_upgrade;
}
}
}