Search code examples
laraveldockerdocker-composelaravel-9swoole

Why Laravel doesn't accept changes until I stop swoole


Every time I make some change in Laravel, I need to do php artisan swoole:http stop and after that php artisan swoole:http start. It doesnt see my changes until I do that. Is there any other way to reloading server, or what..Also, when I do docker-compose up -d it starts running, but in app I am getting Connection is refused.. I am new with Docker and Swoole. Can someone explain to me how to use it? Thank you


Solution

  • I assume you're using octane but in general.

    it loads the application into memory and then serves the application from memory. if you're doing local development there is a watcher you can add that will auto-reload when it detects changes.

    https://laravel.com/docs/9.x/octane#watching-for-file-changes