add X-Forwarded-For to nginx config
This commit is contained in:
parent
18a95f5213
commit
a97509bb43
@ -4,6 +4,8 @@ server {
|
|||||||
server_name naominet.jp;
|
server_name naominet.jp;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_pass_request_headers on;
|
||||||
proxy_pass http://localhost:8000/;
|
proxy_pass http://localhost:8000/;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -14,6 +16,8 @@ server {
|
|||||||
server_name your.hostname.here;
|
server_name your.hostname.here;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_pass_request_headers on;
|
||||||
proxy_pass http://localhost:8080/;
|
proxy_pass http://localhost:8080/;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -75,6 +79,8 @@ server {
|
|||||||
ssl_prefer_server_ciphers off;
|
ssl_prefer_server_ciphers off;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_pass_request_headers on;
|
||||||
proxy_pass http://localhost:8080/;
|
proxy_pass http://localhost:8080/;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -95,6 +101,8 @@ server {
|
|||||||
ssl_prefer_server_ciphers off;
|
ssl_prefer_server_ciphers off;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_pass_request_headers on;
|
||||||
proxy_pass http://localhost:8080/SDBT/104/;
|
proxy_pass http://localhost:8080/SDBT/104/;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -131,6 +139,8 @@ server {
|
|||||||
add_header Strict-Transport-Security "max-age=63072000" always;
|
add_header Strict-Transport-Security "max-age=63072000" always;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_pass_request_headers on;
|
||||||
proxy_pass http://localhost:8090/;
|
proxy_pass http://localhost:8090/;
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user