File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed
Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change 1+ server {
2+ listen 80;
3+ server_name localhost; # Or your-domain.com if you have one
4+
5+ location / {
6+ # 'gym-api' matches the service name in docker-compose.yml
7+ # '8080' matches the internal port of your .NET app
8+ proxy_pass http://gym-api:8080;
9+
10+ # These headers are CRITICAL for the "ForwardedHeaders" logic
11+ # we added to your Program.cs to work correctly.
12+ proxy_http_version 1.1;
13+ proxy_set_header Upgrade $http_upgrade;
14+ proxy_set_header Connection keep-alive;
15+ proxy_set_header Host $host;
16+ proxy_set_header X-Real-IP $remote_addr;
17+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
18+ proxy_set_header X-Forwarded-Proto $scheme;
19+ proxy_cache_bypass $http_upgrade;
20+ }
21+ }
You can’t perform that action at this time.
0 commit comments