Skip to content

Commit

Permalink
πŸ“¦ chore: nginx 헀더 IP 전달 μ„€μ •
Browse files Browse the repository at this point in the history
  • Loading branch information
asn6878 committed Jan 1, 2025
1 parent 38a43c8 commit c8a772f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ server {
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
proxy_read_timeout 3600s;

proxy_set_header Host $host; # Host ν—€λ”λ‘œ host λ³€μˆ˜κ°’ 전달
proxy_set_header X-Real-IP $remote_addr; # X-Real-IP ν—€λ”λ‘œ μ‹€μ œ IP 전달
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; # X-Forwarded-For ν—€λ”λ‘œ μ‹€μ œ IP 전달
proxy_set_header X-Forwarded-Proto $scheme; # ν΄λΌμ΄μ–ΈνŠΈμ˜ ν”„λ‘œν† μ½œ 전달
}

# WebSocket μš”μ²­ ν”„λ‘μ‹œ
Expand All @@ -50,5 +55,10 @@ server {
proxy_cache_bypass $http_upgrade;
proxy_read_timeout 3600s;
proxy_send_timeout 3600s;

proxy_set_header Host $host; # Host ν—€λ”λ‘œ host λ³€μˆ˜κ°’ 전달
proxy_set_header X-Real-IP $remote_addr; # X-Real-IP ν—€λ”λ‘œ μ‹€μ œ IP 전달
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; # X-Forwarded-For ν—€λ”λ‘œ μ‹€μ œ IP 전달
proxy_set_header X-Forwarded-Proto $scheme; # ν΄λΌμ΄μ–ΈνŠΈμ˜ ν”„λ‘œν† μ½œ 전달
}
}

0 comments on commit c8a772f

Please sign in to comment.