SpringCloudGate 集群配合nginx配置服务网关负载均衡

SpringCloudGate 集群配合nginx配置服务网关负载均衡    

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    upstream gatewayserver{
        server 127.0.0.1:8851 weight=1;
        server 127.0.0.1:8852 weight=1;
        server 127.0.0.1:8853 weight=1;
    }
    
    server {
        listen       80;
        server_name  gateway.cluster;

        location / {
            proxy_pass  http://gatewayserver/;
          }
    }
}

你可能感兴趣的:(spring,cloud,负载均衡,eureka)