nginx 转发配置

负载均衡
    upstream test_http{
       server 172.28.12.31:8001 weight=1;
       server 172.28.12.33:8002 weight=1;
    } 
https-ssl证书
    # HTTPS server
    server {
        listen       9090 ssl;
        server_name  domain.name;
        ssl_certificate      cert/name.pem;
        ssl_certificate_key  cert/name.key;
        ssl_session_timeout  5m;
        ssl_ciphers  ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
        ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
        ssl_prefer_server_ciphers  on;
转发
        location / {
			proxy_pass http://test_http;
			proxy_set_header X-Real-IP $remote_addr;
			proxy_set_header REMOTE-HOST $remote_addr;
			proxy_set_header Host $host;
			proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        }
监控status		
	location /status {
	                stub_status on;
	                access_log off;
                        allow 127.0.0.1;
			deny all;
			}
    }
原文地址:https://www.cnblogs.com/kylingx/p/12334504.html