Laravel Homstead-仅显示服务器502错误而不是Laravel错误 [英] Laravel Homstead - Only showing server 502 error instead of Laravel error
问题描述
我将应用程序切换为使用Laravel Homestead.一切正常!但是,现在并没有向我显示错误,而只是向我显示了来自Nginx服务器的502错误网关.是否有设置或可以用来通过Laravel错误处理程序向我显示错误的内容?如果没有显示错误,就无法测试我的问题.
I switched my application to use Laravel Homestead. Everything works great! However, now instead of showing me errors as they come about it is only showing me a 502 bad gateway from the nginx server. Is there a setting or something I could use to make sure it shows me the error via the Laravel error handler? It's impossible to test my issues if it's not showing me an error.
我已将调试设置为"true",并且我不确定可以提供什么其他信息,因为它在我的本地apache设置中可以正常工作.
I have debug set to "true" and I am not sure what other information I can provide to help since it works fine on my local apache setup.
推荐答案
将两行添加到Nginx配置文件/etc/nginx/nginx.conf
Add two lines to Nginx configuration file /etc/nginx/nginx.conf
http {
...
fastcgi_buffers 8 16k;
fastcgi_buffer_size 32k;
...
}
然后重新启动nginx服务器:)
And restart nginx server :)
这篇关于Laravel Homstead-仅显示服务器502错误而不是Laravel错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!