建议直接修改conf文件
下面是不带www强制跳转到带www,并开启https
server
{
listen 80;
server_name abcd.com www.bacd.com;
rewrite ^(.*)$ https://www.bacd.com$1 permanent;
}
server
{
listen 443 ssl http2;
index index.php index.html index.htm default.php default.htm default.html;
此处省略N 个字配置
} |
|