1.版本
nginx version: nginx/1.12.2
2.配置
events{
}
http{
upstream test{
server localhost:1234 weight=1;
server localhost:1235 weight=1;
}
server {
listen 80;
location / {
proxy_pass http://test;
}
}
}
此时访问80端口会按1:1的概率随机分配到1234 1235两个端口