nginx 主配置文件加入
upstream myapp1 {server 192.168.124.101:5051;server 192.168.124.102:5052;server 192.168.124.111:5050;}
站点配置文件中加入
location / {proxy_pass http://myapp1;}
80端口映射到外网域名配置方法
加入红框中的代码
upstream myapp3 {server 192.168.124.101:5051;server 192.168.124.102:5052;server 192.168.124.111:5050;}