This is a docker setup for Laravel development and can be used with any of its versions. This example was done with Laravel 10. In addition, it can be used with Inertia and Livewire.
NodeJS can run on local machine for development.
- docker compose up -d
- docker-compose exec app bash
- Laravel deployment commands (check Laravel docs about deployment)
- exit
- npm run dev
- Go to localhost:8000
- Done!
ERR_CONNECTION_REFUSED
Solution: delete public/hot and rebuild the application