lnmp vhost add 添加完后,修改域名配置文件

root  /home/wwwroot/域名目录/public;    //工作目录配置到public
 

修改fastcgi.conf

#fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/";
fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/../:/tmp/:/proc/";

  

配置重写,统一放在 other.conf,因为所有的域名配置文件均引用了该配置

location / {
            if (!-e $request_filename){
                rewrite ^/(.*)$ /index.php?s=/$1 last;
            }
}

 

相关文章:

  • 2021-07-02
  • 2021-04-21
  • 2022-12-23
  • 2021-11-05
  • 2021-11-14
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-04-01
  • 2022-02-06
  • 2022-12-23
  • 2022-01-12
  • 2022-02-16
  • 2022-12-23
相关资源
相似解决方案