1)编辑vi nginx.conf,找到http{} 在里面加入
upstream ucentertomcat {
server 192.168.100.108:8080 weight=1;
server 192.168.100.105:8080 weight=1;
server 192.168.100.106:8080 weight=1;
}
在server{}里面加入
location /ucenter {
proxy_pass http://ucentertomcat;
index index.html index.htm;
}
时间: 2024-10-25 09:47:32