Search code examples
laravelhomestead

How to solve "Eloquent error: A facade root has not been set" when installing Homestead 8.0.0 on Mac


I'm installing Laravel Homestead for the first time. The installation process seems to work fine, but I get an error when I try to connect to the virtual machine.

Up to this point all my Laravel development work has been done using PHP stack on my Mac.

I have followed the step-by-step instructions at https://laravel.com/docs/5.8/homestead

Installation works fine, and I can vagrant ssh and see the Homestead 8.0.0 installation working fine.

The problem comes when I try to view the site being served. I browse to homestead.test or 192.168.10.10

I expect to see the Laravel project displayed in the browser. Instead, I see an error message:

Eloquent error: A facade root has not been set

I know that the code is correct, because I can see it fine if I use php artisan serve on my local machine.

I have reinstalled Vagrant and Homestead countless times now, and made sure VirtualBox is updated. What should I try next to troubleshoot this?


Solution

  • You could try downgrading Homestead to 7.2 version, like in this answer. https://stackoverflow.com/a/56464835/757587

    I had similar problem that got resolved by upgrading my VirtualBox 6. Are you absolutely sure you have VirtualBox on v6 (and everything else updated), and not something like v5 where you might have it up to date for that version only.