Laravel环境 nginx配置了Https访问,除了首页面可以正常访问,其他路由都是404,查了很多资料没找到原因;如果换成http访问,所有访问都是正常的;请帮忙看看;这是我的配置
listen 443 ssl http2 default_server;
listen [::]:443 ssl http2 default_server;
ssl_certificate localhost.pem;
ssl_certificate_key localhost.key;
ssl_session_timeout 5m;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
server_name localhost;
root /data/wwwwroot/project/public;
index index.php index.html index.htm;
location ~ [^/]\.php(/|$) {
fastcgi_pass 127.0.0.1:9000;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
location / {
try_files $uri $uri/ /index.php?$query_string;
}