相关配置文件php
Nginx 配置文件:/usr/local/nginx/conf/nginx.confhtml
PHP 配置文件: /usr/local/php/etc/php.ininginx
MySQL配置文件: /etc/my.cnflaravel
默认网站根目录: /home/wwwroot/defaultbootstrap
搭建常见问题:app
报错1: 403 Foribiddencomposer
检查目录所属者是否和/usr/local/nginx/conf/nginx.conf中的用户名一致php-fpm
报错2:关于PHP的报错网站
编辑/usr/local/php/etc/php.ini中disable_function 相应的方法便可ui
情景:nginx.conf网站更目录更改之后报以上错误
编辑/usr/local/php/etc/php.ini打开错误信息提示
display_errors = On
display_startup_errors = On
修改完重启php-fpm lnmp php-fpm stop|start
错误日志显示,访问脚本不在 open_basedir的限定目录里面,配置open_basedir 通常会在php.ini 或 nginx 配置文件里面
error in exception handler: The stream or file "/var/www/laravel/app/storage/logs/laravel.log" could not be opened: failed to open stream: Permission denied in /var/www/laravel/bootstrap/compiled.php:8423
在应用目录下执行命令
chmod -R 777 storage/