mardi 2 octobre 2018

Laravel backpack installation: "The command composer failed"

I get the following error while trying to install Laravel Backpack on Laravel 5.6.38:

xxx@yyy.eu [~/www/myapp]# sp-php artisan backpack:base:install
 0/6 [░░░░░░░░░░░░░░░░░░░░░░░░░░░░]   0% Backpack\Base installation started. Please wait...
 1/6 [▓▓▓▓░░░░░░░░░░░░░░░░░░░░░░░░]  16% Installing backpack/generators

   Symfony\Component\Process\Exception\ProcessFailedException  : The command "composer require backpack/generators --dev" failed.

Exit Code: 255(Unknown error)

Working directory: /home/xxx/public_html/myapp

Output:
================


Error Output:
================


  at /home/xxx/public_html/myapp/vendor/backpack/base/src/app/Console/Commands/Install.php:94
    90|         });
    91|
    92|         // executes after the command finishes
    93|         if (!$process->isSuccessful()) {
  > 94|             throw new ProcessFailedException($process);
    95|         }
    96|
    97|         if ($this->progressBar) {
    98|             $this->progressBar->advance();

  Exception trace:

  1   Backpack\Base\app\Console\Commands\Install::executeProcess("composer require backpack/generators --dev")
      /home/xxx/public_html/myapp/vendor/backpack/base/src/app/Console/Commands/Install.php:52

  2   Backpack\Base\app\Console\Commands\Install::handle()
      /home/xxx/public_html/myapp/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:29

  Please use the argument -v to see more details.

If I call composer require backpack/generators --dev manually, it works perfectly.

Some other info on my environment: working on a domain where php has been changed manually to 7.2 from 5.4 via cPanel's multi php manager.

Also this is the alias of my composer:

xxx@yyy.eu [~/www/myapp]# alias composer
alias composer='sp-php /home/xxx/composer.phar'

sp-php points to the php7.2 binary. php composer.phar wouldn't work cause php still points to the php5.4 binary on this domain.

Any idea what could cause this error?



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire