# NGINX Configuration for Local Development # Configuração simplificada para testes locais events { worker_connections 1024; } http { include /etc/nginx/mime.types; default_type application/octet-stream; # Log format log_format main '$remote_addr - $remote_user [$time_local] "$request" ' '$status $body_bytes_sent "$http_referer" ' '"$http_user_agent" "$http_x_forwarded_for"'; access_log /var/log/nginx/access.log main; error_log /var/log/nginx/error.log; # Upstream para desenvolvimento local upstream bcards_local { server bcards-test-app:8080; } server { listen 80; server_name localhost; # Health check do NGINX location = /nginx-health { access_log off; return 200 "nginx ok\n"; add_header Content-Type text/plain; } # Proxy para aplicação location / { proxy_pass http://bcards_local; 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; # Timeouts para desenvolvimento proxy_connect_timeout 10s; proxy_send_timeout 10s; proxy_read_timeout 10s; } } }