Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

deadrabbits's avatar

Laravel passport on docker not working

I have a Laravel application on my local and implement Laravel Passport. I have an API route to return tokens for password grant type. I follow the official documentation https://laravel.com/docs/8.x/passport#requesting-password-grant-tokens to make it. when I run Laravel with php artisan serve it is working. But when I try to dockerize my Laravel and hit that API route using postman. the postman sending the request and I waiting so long. then I decided to cancel the request.

can anyone tell me what the problem? can you give me an example docker compose that have laravel passport works? I have search in google, and not found laravel passport working on docker container

0 likes
1 reply

Please or to participate in this conversation.