【发布时间】:2016-10-18 17:41:15
【问题描述】:
当我尝试运行我的 laravel 5.2 应用程序时,我遇到了这个问题
ErrorException in Filesystem.php line 109:
file_put_contents(/91d1527fa409639235e4cf4fb0164907d94d4dce.php): failed to open stream: Permission denied
我完全允许我的 laravel 文件夹和存储文件夹。但仍然面临这个问题。我正在使用 Ubuntu 操作系统
【问题讨论】:
-
您是否授予该目录至少 755 的权限,并且 www-data 是否是该目录的所有者?
-
是的,我给了 755 权限
-
尝试运行 php artisan cache:clear from the project directory,然后 chmod -R 777 app/storage 最后是 php artisan dump-autoload。
-
@claudios 你知道给 777 权限不好对吧? 755就够了
-
@MuthaFury,是的,我知道。只需检查它是否有效,然后尝试改回 755。
标签: php laravel ubuntu laravel-5.2