animeic 1 жил өмнө
parent
commit
056f3a6bd1

+ 5 - 3
nginx/conf.d/default.conf

@@ -14,10 +14,12 @@ server {
 
     # 支付接口
     location /pay/ {
-        proxy_set_header Host $host;
-        proxy_set_header X-Forwarded-For $remote_addr;
-        proxy_set_header X-Forwarded-Host $server_name;
+        # proxy_set_header Host $host;
+        # proxy_set_header X-Forwarded-For $remote_addr;
+        # proxy_set_header X-Forwarded-Host $server_name;
+        # proxy_set_header X-Real-IP $remote_addr;
         proxy_set_header X-Real-IP $remote_addr;
+        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
         # real_client_ip = $realip_remote_addr;
         proxy_pass  http://pay:8888/pay/;
     }