laravel / sail

Docker files for running a basic Laravel application.
https://laravel.com/docs/sail
MIT License
1.65k stars 470 forks source link

Very slow on MacOS #713

Closed francoism90 closed 1 month ago

francoism90 commented 1 month ago

Sail Version

1.31.0

Laravel Version

10.48.18

PHP Version

8.3.9

Operating System

macOS

OS Version

14.5

Description

Since a month I have very slow response times with Laravel Sail on my MacOS development machine. I tried everything, like increasing resources, use caches, etc., but nothing helps.

The following errors occur when the Laravel-app becomes slow:

laravel.test-1  | 2024-08-06 08:30:03,980 INFO reaped unknown pid 711 (exit status 0)
laravel.test-1  | 2024-08-06 08:30:03,981 INFO reaped unknown pid 714 (exit status 0)

For some reason it seems to kill or wait for something?

Do you have idea how to debug this? The project runs fine on production.

Steps To Reproduce

  1. Clone project
  2. Run sail up
  3. INFO reaped unknown pid message
  4. Very slow app load (30 seconds or more)
Jubeki commented 1 month ago

Can you add the link to the project? I have no problems so far with my Sail-Projects.

francoism90 commented 1 month ago

@Jubeki It's a close project unfortunately.

I have the same on a clean Laravel app as well, it simply seems to hang somewhere. I have plenty of free memory and space.

driesvints commented 1 month ago

Hi there,

Thanks for reporting but it looks like this is a question which can be asked on a support channel. Please only use this issue tracker for reporting bugs with the library itself. If you have a question on how to use functionality provided by this repo you can try one of the following channels:

However, this issue will not be locked and everyone is still free to discuss solutions to your problem!

Thanks.

Jubeki commented 1 month ago

Did you try clearing/purging build images, deleting containers and the volumes and/or setting up a new version of Docker?

(Can't help more than that unfortunately)

fmmek commented 1 month ago

I have the same issue, i noticed this first when being forced by my employer to switch to maOS, all my Laravel projects in sail on macOS seem to have this issue.

During development my initial page load is very slow up to 10 seconds. even on the simplest welcome page. After loading it's almost instant on consecutive refreshes. Then after waiting a couple seconds or minutes during working in my IDE, the first load is again 10 seconds. This is a lot of time throughout a full day. I only have this problem on macOS, never in windows or linux.

francoism90 commented 1 month ago

@Jubeki Thanks for your help. :)

Yes, I have cleared/purged the containers, including reinstalling Docker using brew, instead of directly installing the app.