The stream or file "/var/www/maheshiya.com/public_html/storage/logs/laravel-2019-02-06.log" could not be opened: failed to open stream: Permission denied
How to fix this eror? Centos 7
The stream or file "/var/www/maheshiya.com/public_html/storage/logs/laravel-2019-02-06.log" could not be opened: failed to open stream: Permission denied
How to fix this eror? Centos 7
The proper solution is not to give every user on a server access to your storage directory or logs.
The proper solutions are either:
Don't run artisan commands as other users so the log files aren't created/owned by another user. Run chown on the log files so the proper user owns it to correct this.
chown -R user storage/logs
Or