upstream tiup { server 127.0.0.1:8000; keepalive 80; } server { listen 80; ## listen for ipv4; this line is default and implied # Make site accessible from http://localhost/ server_name telemetry.pingcap.com; access_log /var/log/nginx/tiup_access.log main; error_log /var/log/nginx/tiup_err.log; gzip on; gzip_vary on; gzip_types *; gzip_min_length 1000; client_max_body_size 100M; ## Ucloud redirect if ($http_x_forwarded_proto = "http") { return 301 https://$server_name$request_uri; } location / { proxy_set_header Host $http_host; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_http_version 1.1; proxy_set_header Connection ""; proxy_pass http://tiup; } }