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

murilo's avatar
Level 10

The command "'composer' 'require' 'laravel/passport:^12.0'" failed in laravel 11

hello , I have hre laravel passport installed with the version - "laravel/passport": "^12.2",

I am trying to install the api with -

artisan install:api --passport

but it is giving this error -

Symfony\Component\Process\Exception\ProcessStartFailedException 

  The command "'composer' 'require' 'laravel/passport:^12.0'" failed.

Working directory: /var/www/html

Error: proc_open(): posix_spawn() failed: No such file or directory

  at vendor/symfony/process/Process.php:371
    367▕             restore_error_handler();
    368▕         }
    369▕ 
    370▕         if (!\is_resource($process)) {
  ➜ 371▕             throw new ProcessStartFailedException($this, $lastError);
    372▕         }
    373▕         $this->process = $process;
    374▕         $this->status = self::STATUS_STARTED;
    375▕ 

I did -

artisan config:cache
composer dump-autoload

but still not working

0 likes
2 replies

Please or to participate in this conversation.