nginx 配置如下
...
upstream vast_upstream{
server 192.168.22.188:8080;
server 192.168.22.188:8081;
server 192.168.22.188:8082;
}
server{
listen 9090;
server localhost;
localtion / {
proxy_pass http://vast_upstream/;
}
}
...
经查阅 未配置 proxy_set_header
修改为如下代码
...
upstream vast_upstream{
server 192.168.22.188:8080;
server 192.168.22.188:8081;
server 192.168.22.188:8082;
}
server{
listen 9090;
server localhost;
localtion / {
proxy_set_header Host $host;
proxy_pass http://vast_upstream/;
}
}
...
访问接口 可以正常访问
特此记录