fastcgi_intercept_errors on;
server {
listen 80;
server_name www.abc.com;
rewrite ^(.*)$ https://$host$1 permanent;
}
server {
listen 443;
server_name www.abc.com;
root html/www;
index index.php index.html index.htm;
#https证书
ssl on;
ssl_certificate /application/nginx/conf/key/server.crt;
ssl_certificate_key /application/nginx/conf/key/server.key;
#访问日志
access_log logs/access_www.log main;
#隐藏版本号
&