0

I want to install composer for using laravel in Ubuntu 17.10, when I tried it gives me error.

I tried those methods;

Errors;

$ php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
  PHP Warning:  copy(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in Command line code on line 1
PHP Warning:  copy(): Failed to enable crypto in Command line code on line 1
PHP Warning:  copy(https://getcomposer.org/installer): failed to open stream: operation failed in Command line code on line 1

And:

$ php -r "if (hash_file('SHA384', 'composer-setup.php') === '669656bab3166a7aff8a7506b8cb2d1c292f042046c5a994c43155c0be6190fa0355160742ab2e1c88d40d5be660b410') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
Installer corrupt

What I need to do ?

muru
  • 193,181
  • 53
  • 473
  • 722
Hasan Tıngır
  • 267
  • 4
  • 18
  • Please [edit] and actually post the error message in its entirety. –  Nov 01 '17 at 20:30
  • @MichaelBay Edited and updated – Hasan Tıngır Nov 01 '17 at 20:43
  • certificate verify failed? Are you behind a firewall or proxy or something? – muru Nov 02 '17 at 08:00
  • If you want to install the latest version of composer visit this question: [Unable to download composer](https://askubuntu.com/questions/820803/unable-download-composer) – karel Nov 02 '17 at 12:16
  • Finally installed but, this time I cant setup laravel packages, gives me missing php extension error, https://stackoverflow.com/questions/47071133/laravel-installing-error-missing-php-extension/47071210#47071210 – Hasan Tıngır Nov 02 '17 at 17:56

0 Answers0