80转443:
server { listen 80; server_name huashengshu.top; rewrite ^(.*)$ https://${server_name}$1 permanent; }
404报错:
http { proxy_intercept_errors on; ##不加此项,后面开启了404也无法跳转 server { ... ....
error_page 404 /404.html; ##404跳转 location = /404.html { root /etc/nginx/html/404; } } }