我的导轨应用程序有问题。
该应用程序的API是在端口8082上的本地主机上查找我的论坛(forum.example.com)。
我需要创build一个路线,redirect每个连接到forum.example.com 127.0.0.1:8082
用nginx可以得到这样的东西吗?
我会用这个proxy_pass 。
在nginx中,创build一个虚拟主机,监听端口8082的localhost ,然后将其代理到forum.example.com 。
像这样的东西:
server { listen 8082; server_name 127.0.0.1; location / { proxy_pass http://forum.example.com; } }