upstream xx {
server 127.0.0.1:1800 weight=1;
ip_hash;
}

server {
listen 80;
server_name xx.xx.com;
location / {
rewrite ^(.*)$ https://xx.xxcom$1 permanent;
}
}

server {
listen 443 ssl;
server_name xx.xx.com;

server_tokens off;
gzip on;
gzip_comp_level 6;
# gzip_proxied any;
gzip_types text/plain text/css application/json application/javascript application/x-javascript text/xml application/xml application/xml+rss text/javascript application/x-font-woff;

location / {
proxy_pass http://xx;
proxy_set_header Host jumpserver.factorybi.com;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}

ssl_certificate /etc/nginx/ssl/xx.pem;
ssl_certificate_key /etc/nginx/ssl/xx.key;
ssl_session_timeout 5m;
ssl_ciphers EECDH+ECDSA+AESGCM:EECDH+aRSA+AESGCM:EECDH+ECDSA+SHA384:EECDH+ECDSA+SHA256:EECDH+aRSA+SHA384:EECDH+aRSA+SHA256:EECDH+aRSA+RC4:EECDH:EDH+aRSA:!aNULL:!eNULL:!LOW:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS:!RC4;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
}