Skip to content

Latest commit

 

History

History
20 lines (18 loc) · 308 Bytes

Nginx-7-Proxy-1.md

File metadata and controls

20 lines (18 loc) · 308 Bytes

简单的负载平衡

http {
upstream myproject {
    server 127.0.0.1:8000 weight=3;
    server 127.0.0.1:8001;
    server 127.0.0.1:8002;
    server 127.0.0.1:8003;
}

server {
    listen 80;
    server_name www.domain.com;
    location / {
    proxy_pass http://myproject;
    }
}
}