Now there is a proxy server, and I want to access api.php in the root directory of the intranet web machine through proxy. How should I configure proxy forwarding?
I wrote it like this, but it didn’t seem to work. I added an api.html
location ~ /api.html {
proxy_pass http://192.168.10.2:80/api.php;
}
Please give me some advice!
Try
rewrite api.html http://192.168.10.2:80/api.php permanent;