gpt4 book ai didi

php - Composer 安装失败

转载 作者:行者123 更新时间:2023-12-03 02:31:50 24 4
gpt4 key购买 nike

我正在尝试在 Ubuntu 16.04 中使用 PHP 版本 5.6.* 安装 Composer。

我使用:curl -sS https://getcomposer.org/installer | php.但它给我错误如下:

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.

我之前没有安装 Composer。

最佳答案

我通过下载https://curl.haxx.se/ca/cacert.pem解决了这个问题并在我的 etc/php/5.6/cli/php.inietc/php/5.6/apache2/php.ini 中给出它的路径。

然后运行 ​​sudo service apache2 restart && sudo apt installcomposer 就可以正常工作了。

关于php - Composer 安装失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48241939/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com