Single-threaded servers
Fix requests that hang when you run Nimbus with php artisan serve or Laravel Sail.
The problem
These servers handle one request at a time. When you click Send, the relay endpoint makes a second request to your API on the same server. The server is busy with the first request, so the second one waits until it times out.
When this happens, Nimbus shows an error with the value to use for base_url. nimbus:doctor reports it as a warning on the single threaded server check.
The fix
Run two server processes on different ports. One serves the Nimbus page and the relay, and the other answers the API requests.
Start the first server.
Terminalphp artisan serve --port=8000Start a second server in another terminal.
Terminalphp artisan serve --port=8001With Sail, run
./vendor/bin/sail artisan serve --port=8001for the second one.Set
base_urlinconfig/nimbus.phpto the second server.php'base_url' => 'http://127.0.0.1:8001',Open
http://127.0.0.1:8000/nimbus.
Expected result
Requests from Nimbus reach your API through the second server and return normally.
Other options
A server that handles requests in parallel needs no workaround. Laravel Herd, Nginx with PHP-FPM, and Apache all work.