http2.0
在nginx中的配置:
upstream xxx_service { server host.docker.internal:10003; } server { listen 443 ssl; http2 on; ssl_certificate /path/xxx.com.pem; ssl_certificate_key /path/xxx.com.key; # 启用的 SSL 协议,确保向后兼容到 HTTP/1.1 ssl_protocols TLSv1.2 TLSv1.3; # 其他 SSL 配置,比如密码套件和性能优化等 ssl_ciphers 'ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384'; ssl_prefer_server_ciphers on; server_name xxx.com; #charset koi8-r; #log_format main '$remote_addr - $remote_user [$time_local] "$request" ' # '$status $body_bytes_sent "$http_referer" ' # '"$http_user_agent" "$http_x_forwarded_for"'; #access_log /usr/local/openresty/nginx/logs/access.log main; location ~ ^/(feed|product) { proxy_pass http://xxx_service; } error_page 500 502 503 504 /50x.html; location = /50x.html { root /usr/local/openresty/nginx/html; } }
浙公网安备 33010602011771号