繁体   English   中英

如何在公司代理后面安装 PECL 包?

[英]How to install PECL package behind a corporate proxy?

我已经配置了pear config-set http_proxy "$http_proxy" ,但这没有任何效果。

看看下面,看看我得到的输出是什么:

pecl install bz2
WARNING: "pear/bz2" is deprecated in favor of "channel://http://php.net/bzip2/ext/bz2"

Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in PEAR/Proxy.php on line 101

Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /usr/local/lib/php/PEAR/Proxy.php on line 101

Notice: Undefined variable: proxy_host in PEAR/Proxy.php on line 103

Notice: Undefined variable: proxy_port in PEAR/Proxy.php on line 103

Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in PEAR/Proxy.php on line 101

Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /usr/local/lib/php/PEAR/Proxy.php on line 101

Notice: Undefined variable: proxy_host in PEAR/Proxy.php on line 103

Notice: Undefined variable: proxy_port in PEAR/Proxy.php on line 103
Could not establish SSL connection through proxy ::

我有同样的问题。

我通过将以下内容添加到php.ini解决了这个问题,所有错误都消失了。

openssl.cafile=/etc/ssl/certs/ca-bundle.trust.crt

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM