简体   繁体   中英

Laravel permission denied errors

I made a website and the website got error on the server . But there is no problem on my local. When I send code to git , I got error file put content . When I use php artisan view:cache problem solved but some hours later I got error file put content permission denied automatically.

I investigated for this problem and I found chmod -R 777 command but I got this error again . I don't know how to solve this problem .

May you please help me ?

Thanks in advance.

Try this..Whichever way you set it up, then you need to give read and write permissions to the webserver for storage, cache

sudo chgrp -R www-data storage bootstrap/cache
sudo chmod -R ug+rwx storage bootstrap/cache

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM