相關配置文件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/