0
我正在开发一个网站,并且我刚刚在生产网站上安装了ssl
(我从来没有这样做过)。当我加载开发网站时,由于https未安装在开发站点上,因此页面重定向到https并中断。在开发服务器上,主机文件和nginx从http重定向到https
- 发展网址:http://local.ezel.io
- 生产网址:https://ezel.io
Nginx的(生产):
server{
listen 80;
server_name ezel.io;
root /var/www/ezel.io/public;
location ~ /.well-known {
allow all;
}
rewrite^https://$server_name$request_uri? permanent;
}
Nginx的(发展):
server {
listen 80;
server_name local.ezel.io;
root /home/ryan/Documents/www/ezel.io/public;
index index.php index.html index.htm;
location/{
try_files $uri $uri/ /index.php?$query_string;
}
location ~ \.php$ {
fastcgi_pass unix:/run/php/php7.0-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}
在我的机器,我也有我的hosts文件如下:
127.0.0.1 local.ezel.io
什么会是导致我去从http://local.ezel.io到https://local.ezel.io?