标签 https 下的文章
# 监听80端口,http请求转发到https监听的443端口 server { listen 80; server_name localhost; return 301 https://$server_name$request_uri; } # 监听443端口,https请求 server { listen 443 ssl; root /var/www/html; index index.php index.html index.htm; server_name localhost; ssl on; ssl_certificate /etc/nginx/ssl/cert.crt; # 证书路径 ssl_certificate_key /etc/nginx/ssl/cert.key; # 证书路径 ssl_session_timeout 5m; ssl_protocols TLSv1 TLSv1.1 TLSv1....
nginx服务器配置https

nginx服务器配置https