用的宝塔面板,具体情况是网站开了证书,做了http转https,不过现在80端口好像不能访问,用火狐访问报的连接被重置,360浏览器一直不停的刷新,也不跳转,然后我用curl -v 得到的反馈是
- About to connect() to www.***.com port 80 (#0)
- Trying 221.*.*.141...
-
Connected to www.***.com (221.*.*.141) port 80 (#0)
GET / HTTP/1.1
User-Agent: curl/7.29.0
Host: www.***.com
Accept: /< HTTP/1.1 301 Moved Permanently
301 Moved Permanently
< Server: nginx
< Date: Wed, 30 Oct 2019 20:46:41 GMT
< Content-Type: text/html
< Content-Length: 162
< Connection: keep-alive
< Location: https://www.***.com/
<301 Moved Permanently
nginx
(避免误认为发广告,打个马赛克)-------
下面是网站配置文件
listen 80;
listen 443 ssl http2;
server_name www.***.com;
index index.php index.html index.htm default.php default.htm default.html;
root /www/wwwroot/www.***.com;#SSL-START SSL相关配置,请勿删除或修改下一行带注释的404规则
#error_page 404/404.html;
#HTTP_TO_HTTPS_START
if ($server_port !~ 443){
rewrite ^(/.*)$ https://$host$1 permanent;
}
#HTTP_TO_HTTPS_END
ssl_certificate /www/server/panel/vhost/cert/www.***.com/fullchain.pem;
ssl_certificate_key /www/server/panel/vhost/cert/www.***.com/privkey.pem;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE;
ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;error_page 497 https://$host$request_uri;
请处理过或知道这个故障的大佬,帮忙一下,百度也搜过找不到问题,非常感谢