laravelnginxphp-7

Laravel proper permissions


I just tried to change my Laravel project to run on Nginx instead of Apache and can't get the right permissions. Don't really know what to try next. Currently here they are: enter image description here

I even gave the 777 permission to the storage folder, but nothing works. I have an admin panel on a blog which always keeps throwing

ErrorException in File.php line 190:
chmod(): Operation not permitted

Would really appreciate any help.

I am using Nginx, PHP 7.0, MySQL. The website is written using the Laravel framework.


Solution

  • This will work, as777 is a security risk

     sudo chmod -R o+w storage/
    
     sudo chmod -R 775 storage/