繁体   English   中英

错误:无法从私有 SVN 服务器安装 R 包

[英]Error: Unable to install R package from private SVN server

在我的 Windows 10 机器 (x64) 上,我尝试使用此处给出的说明从我们的私有 SVN 服务器(Visual SVN 服务器)安装R包(在R Studio )。 服务器具有自签名证书。 要安装该软件包,我正在运行以下命令:

install.packages("https://~path_to_private_SVN/trunk", repos = NULL, type = "source", method="curl", extra = "--user my_username:my_password")

我收到此错误消息:

 Installing package into ‘path_to_R_library/3.5’
    (as ‘lib’ is unspecified)
    % Total    % Received % Xferd  Average Speed   Time    Time     Time Current
                                 Dload  Upload   Total   Spent    Left  Speed
     0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: https://curl.haxx.se/docs/sslcerts.html

curl performs SSL certificate verification by default, using a "bundle"
 of Certificate Authority (CA) public keys (CA certs). If the default
 bundle file isn't adequate, you can specify an alternate file
 using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
 the bundle, the certificate verification probably failed due to a
 problem with the certificate (it might be expired, or the name might
 not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
 the -k (or --insecure) option.
HTTPS-proxy has similar options --proxy-cacert and --proxy-insecure.
Error in download.file(p, destfile, method, mode = "wb", ...) : 
  'curl' call had nonzero exit status

显然, R Studio对 SVN 服务器证书问题不满意,我无法安装 R 包。 不过,目前我想忽略这个SVN服务器的证书错误问题。 有没有办法告诉install.packages()不对这个 SVN 主机执行SSL certificate verification 我知道安装R包的另一个选项可能是devtools::install_svn()

服务器的证书有问题,不可信。 您问题中的错误消息指定了解决步骤和解决方法。 例如,您可以在curl禁用证书验证:

如果您想关闭 curl 对证书的验证,请使用 -k(或 --insecure)选项。

有关在服务器上设置服务器证书的信息,请参阅KB134:为 VisualSVN 服务器配置 SSL 证书

暂无
暂无

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

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