[英]Error with file_put_contents() when deploying web app using Laravel Vapor
I just updated my Laravel application to 6.0 to use the new tool Vapor.我刚刚将我的 Laravel 应用程序更新到 6.0 以使用新工具 Vapor。 However, after the deployment process end, I get this error when i access the app using the vanity url:
但是,在部署过程结束后,当我使用虚荣 url 访问应用程序时出现此错误:
ErrorException thrown with message
"file_put_contents(/tmp/storage/framework/sessions/cqDlEgxQSwsYKnBGpPjv94Dvzasa0ECmqF1Rl9xV):
failed to open stream: No such file or directory"
Do you have some ideas about the reason of this error?你对这个错误的原因有什么想法吗? Thank you
谢谢
The best way to solve this problem is, go to directory laravel/bootstrap/cache
and delete config.php
file.解决这个问题的最好方法是,go 到目录
laravel/bootstrap/cache
并删除config.php
文件。
Use this command to clear cache
make permission to write cache
使用此命令清除
cache
使写入cache
的权限
php artisan config:cache
chmod -R 777 storage/
composer dump-autoload
I faced the same issue while deploying a Laravel app using Vapor.我在使用 Vapor 部署 Laravel 应用程序时遇到了同样的问题。
And solved it by并通过
BROADCAST_DRIVER=log
CACHE_DRIVER=file
SESSION_DRIVER=dynamodb
SESSION_LIFETIME=9999
QUEUE_DRIVER=sync
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.