1
nginx proxy_pass和LAN中的虚拟主机返回404
我希望这是有道理的。基本上,我已经使用nginx在MAC上设置了本地服务器,并为proxy_pass设置了以下规则: location /engine/rest { proxy_pass http://somedomain:9080/engine/rest; } location /engine/ { alias /data/www/pln/; index index.html; } location / { root /Applications/MAMP/htdocs/; index index.html index.htm index.php; } 我还运行了一个MAMP服务于虚拟主机,以便可以使用以下配置从Windows PC上访问它: <VirtualHost *:9090> DocumentRoot "/Applications/MAMP/htdocs" ServerAdmin root@localhost ServerName localhost <Directory /Applications/MAMP/htdocs/> AllowOverride All Order allow,deny Allow from all </Directory> </VirtualHost> 我已经在Windows PC中添加了该主机配置: 192.168.1.3 machost …