config:cache cant access storage folder: failed to open stream
After creating configuration cache application breaks, it cant access storage files.
Cache uses absolute server paths and i think it might be some security issue.
Is there a simple solution?
(tried changing permitions to storage with no effect)
try php artisan config:clear and composer dumpautoload
That would help by clearing configuration.
If this doesnt help you can manually delete bootstrap/cache/config.php
this will remove the cached config.
My question however was regarding the absolute paths.
I still want to use configuration cache to sped things up.
So the solution for now was to change absolute path to relative
so for instance :
'files' => '/home/public_html/app/storage/framework/sessions',
if your app basepath is:
/app/public
you can change it to :
'files' => '../storage/framework/sessions',
and it works.
seems little wierd to use relative path this way but for now it has to do.
Still looking for better solution cause this involves generating incorrect paths on server and then fixing them manually.
Please or to participate in this conversation.