nginx 配置代理某个路径 location /test{ proxy_pass http://localhost:8765/test; proxy_set_header Host $http_host; } 其中红色的那句可以保证 post 等请求不会出现301