Composer安装失败 [英] Composer install failed

查看:462
本文介绍了Composer安装失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正尝试在 PHP版本5.6。* Ubuntu 16.04 中安装composer。

I'm trying to install composer in my Ubuntu 16.04 with PHP version 5.6.*.

我使用过: curl -sS https://getcomposer.org/installer | php 。但这给了我以下错误:

I used:curl -sS https://getcomposer.org/installer | php. But it is giving me error as follows:

All settings correct for using Composer
Downloading...
The "https://getcomposer.org/versions" file could not be downloaded: failed to open stream: Connection refused
Retrying...
The "https://getcomposer.org/versions" file could not be downloaded: SSL operation failed with code 1. OpenSSL Error messages:
error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed
Failed to enable crypto
failed to open stream: operation failed
Retrying...
The "https://getcomposer.org/versions" file could not be downloaded: SSL operation failed with code 1. OpenSSL Error messages:
error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed
Failed to enable crypto
failed to open stream: operation failed
The download failed repeatedly, aborting.

我以前没有安装作曲器。

I do not have composer installed previously.

推荐答案

我通过下载 https://解决了该问题curl.haxx.se/ca/cacert.pem 并在我的 etc / php / 5.6 / cli / php.ini 和<$ c $中给出路径c> etc / php / 5.6 / apache2 / php.ini 。

I solved the issue by downloading https://curl.haxx.se/ca/cacert.pem and giving it's path in my etc/php/5.6/cli/php.ini and etc/php/5.6/apache2/php.ini.

然后在运行 sudo服务apache2后重新启动&& sudo apt install composer 正常工作。

这篇关于Composer安装失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆