安装typecho完成后访问后台和文章显示404 修改nginx配置:/home/wwwroot/lnmp01/vhost/typecho.conf
...
location ~ .*\.php(\/.*)*$
{
fastcgi_pass unix:/tmp/php-cgi-lnmp01-typecho.sock;
...
修改重写规则:/home/wwwroot/lnmp01/rewrite/amh.conf
if (-f $request_filename/index.php){
rewrite (.*) $1/index.php;
}
if (!-f $request_filename){
rewrite (.*) /index.php;
}
重启nginx
killall nginx
/usr/local/nginx-generic-1.20/sbin/nginx
本文同步于个人Github博客:https://github.com/cloudswave/blog/issues/25,欢迎留言。