流浪了在Windows 7:错误设置证书验证地点

流浪了在Windows 7:错误设置证书验证地点

问题描述:

我刚刚碰到Vagrant,试图通过入门指导https://www.vagrantup.com/intro/getting-started/index.html流浪了在Windows 7:错误设置证书验证地点

潜水前到您的第一个项目,请安装最新版本的流浪的。而且由于我们将使用VirtualBox作为入门指南的提供者,请安装它。

我的主机是Windows 7 x64Virtualbox5.1.14r112924。虚拟化已启用:我成功使用Windows XP虚拟机。

所以我安装了最新的Vagrant版本2.0.0。我更新Powershell2.05.0修复vagrant up没有任何问题。

所以,从指令入门:

  1. vagrant init hashicorp/precise64:没关系,文件Vagrantfile出现;
  2. vagrant up,入门说:

运行以上两个命令后,你将不得不在VirtualBox的完全运行的虚拟机运行Ubuntu 12.04 LTS 64位。

但我看到:

E:\VM\v_demo>vagrant up 
Bringing machine 'default' up with 'virtualbox' provider... 
==> default: Box 'hashicorp/precise64' could not be found. Attempting to find and install... 
    default: Box Provider: virtualbox 
    default: Box Version: >= 0 
The box 'hashicorp/precise64' could not be found or 
could not be accessed in the remote catalog. If this is a private 
box on HashiCorp's Vagrant Cloud, please verify you're logged in via 
`vagrant login`. Also, please double-check the name. The expanded 
URL and error message are shown below: 

URL: ["https://vagrantcloud.com/hashicorp/precise64"] 
Error: error setting certificate verify locations: 
    CAfile: /mingw64/ssl/certs/ca-bundle.crt 
    CApath: none 

,并在我的工作文件夹下的文件树:

| Vagrantfile 
| 
\---.vagrant 
    \---machines 
     \---default 
      \---virtualbox 
        vagrant_cwd 

互联网搜索这个错误的显示结果约curlиgit但他们这里没有使用。

有关从错误消息中尝试vagrant login的建议也不清楚。截至https://www.vagrantup.com/docs/cli/login.html

命令说:流浪汉登录

login命令用于与HashiCorp的流浪 云服务器进行身份验证。只有在您访问受保护的 框或使用流浪股份时才需要记录日志。

登录不是使用Vagrant的必要条件。绝大多数 Vagrant不需要登录。只有某些功能(如 保护框或Vagrant共享)需要登录。

我不认为测试示例是私人的。 而且我无法在任何地方找到Create account按钮。

我错过了什么?

UPD

Vagrantfile

Vagrant.configure("2") do |config| 
    config.vm.box = "hashicorp/precise64" 
    config.vm.box_download_insecure = true 
end 

config.vm.box_download_insecure = true没有帮助:相同的结果。

UPD2 我已经找到了如何创建帐户https://app.vagrantup.com/account/new(以前我用过的手机版)。 vagrant login没有帮助:相同的结果

+0

尝试加入'config.vm.box_download_insecure = TRUE;在vagrantfile –

+0

@FrédéricHenri,没有帮助,同样的结果。 – and1er

+0

卷曲/ wget的作为其用于下载框,你可以运行'卷曲-O https://开头hashicorp-files.hashicorp.com/precise64.box'下载盒 –

实际的问题是代理服务器。 设置Windows环境变量https_proxy=http://192.168.x.xxx:3128解决了这个问题。

手动解决方案:

  1. 手动从https://hashicorp-files.hashicorp.com/precise64.box下载.box -file到本地文件夹local_box\precise64.box;
  2. 路径添加到本地.box -file内Vagrantfile

    Vagrant.configure("2") do |config| 
    
        config.vm.box = "local_box/precise64.box" 
    
    end 
    
  3. vagrant up现在将按预期。

+0

我想你的解决方案,但我想知道,我做了一个名为'local_box'新的文件夹中的'vagrant'文件夹? –

+0

@NickKing'local_folder'手动创建在'视窗7'只是在命令测试相对路径。没有必要 – and1er