I am very new to Laravel.
I have created a local development site blog.test using command laravel new blog
on MacOS following documentation in Laravel site.
When using command php artisan serve
in ~/Sites/blog
folder then blog.test
is showing Laravel welcome page, but when I am using valet for development then blog.test
is showing It Works
.
Please help solve this issue. What is the missing step?
I already tried below steps
- valet reinstallation
- valet restart
- valet link
it seems that blog.test is pointing to default index.html
file of web server instead of index.php
file in blog/public
folder of Laravel project.
Do I need to configure the web root directory to blog/public
or "valet link" command should take care of this itself?
"It Works" suggests to me that the Mac's built-in Apache server is handling that request. You just need to disable it in order for Valet to take over.
Run
sudo launchctl unload -w /System/Library/LaunchDaemons/org.apache.httpd.plist
to turn off the built-in Apache server.You might also have to restart Valet
valet restart
afterwards.