我正在尝试使用自己的根证书在企业网络上安装Vagrant插件,但它失败了:
$ vagrant plugin install vagrant-timezone --plugin-source http://rubygems.org
Installing the 'vagrant-timezone' plugin. This can take a few minutes...
...
Could not verify the SSL certificate for https://gems.hashicorp.com/.
There is a chance you are experiencing a man-in-the-middle attack, but most likely your system doesn't have the CA certificates needed for verification. For information about OpenSSL certificates, see http://bit.ly/ruby-ssl. To connect without using SSL, edit your Gemfile sources and change 'https' to 'http'.
...
Warning: this Gemfile contains multiple primary sources. Using `source` more than once without a block is a security risk, and may result in installing unexpected gems. To resolve this warning, use a block to indicate which gems should come from the secondary source. To upgrade this warning to an error, run `bundle config disable_multisource true`.Warning: this Gemfile contains multiple primary sources. Using `source` more than once without a block is a security risk, and may result in installing unexpected gems. To resolve this warning, use a block to indicate which gems should come from the secondary source. To upgrade this warning to an error, run `bundle config disable_multisource true`.Retrying fetcher due to error (2/4): Bundler::Fetcher::CertificateFailureError Could not verify the SSL certificate for https://gems.hashicorp.com/.
证书在Web浏览器下工作正常,但不知何故Vagrant不理解这些系统证书。我确实使用http
而不是https
如上所述,但这没有帮助。
针对此类问题的其他解决方法?
curl https://gems.hashicorp.com/
失败了吧?
mixin_install_opts.rb
并更换https
有http
,安静肮脏的解决方法。
https://gems.hashicorp.com/
在浏览器中查看GeoTrust - > RapidSSL - > * .hashicorp.com或您的公司证书吗?