Nginx http 跳转到 https
程序员文章站
2022-03-07 11:13:48
...
if ($server_port = 80) {
rewrite ^(.*)$ https://$host$1 permanent;
}
if ($ssl_protocol = "") {
rewrite ^(.*) https://www.koogay.org/$1 permanent;
}