本文共 383 字,大约阅读时间需要 1 分钟。
server {
listen 80; server_name localhost.com;location / {
proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $http_host; proxy_redirect off; } }加入这几项配置
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $http_host; proxy_redirect off;转载地址:http://gohrn.baihongyu.com/